Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hey guys I dont understand why this find command outputs different results...
find / -uid 1000 VS find / -uid -1000
Why does the command that has a dash in front of the 1000 output so much more text? (the VS is not part of the command it means versus)
You need to read the man page carefully.
Numbers in the find command, as clearly documented, can be without signum (meaning exactly), they can have a leading + (meaning more than), or have a leading - (meaning less than).
Your first command is finding all files and folders belonging to the user with UID 1000. Your second command will find all files and folders belonging to users with UID less than 1000 (including root), thus the MUCH larger list.
Look it up and read carefully.
Thank you both that makes perfect sense I saw those symbols in the man pages, but i didnt know how to interpret them in this case.. One more question i meant to orginally ask but I forgot,
is ps syntax. Why is ps -ax not in the format ps -a x because theres not an -x? They seperate the aguments in this command ps -a f .. This is really confusing cause im not sure how to type them in the proper order..
Last edited by linux4evr5581; 12-28-2016 at 07:53 AM.
Thanks for pointing that out Habitual it says "These options accept a single argument in the form of a blank-seperated or comma-seperated list" But how would the system know if I wanted forest view for f, and not the full format listing option of -f if you can just bunch the commands together with different agument formats like ps -ax does..
Last edited by linux4evr5581; 12-28-2016 at 08:18 AM.
Thanks for pointing that out Habitual it says "These options accept a single argument in the form of a blank-seperated or comma-seperated list" But how would the system know if I wanted forest view for f, and not the full format listing option of -f if you can just bunch the commands together with different agument formats like ps -ax does..
Again, you need to READ.
The man pages clearly state that the command can understand two kinds of short parameters:unix98 (single dash), BSD (no dash). It can also understand GNU parameters (double-dash long form). The pages go on to describe the different behavior of all of the kinds of parameters.
AND that they can be mixed on the command line, and (on my machine at least) how that looks using some examples.
The maintainers do not write all of those long man and info pages for no reason, most of your answers are right there if you only LOOK for it.
Thanks for the response I just think man pages are bland in explanation, cause alot of the time I feel they require you already know what a partiular symbol means for regex, sed/awk etc (in this case bsd/unix/gnu formats, which Idk were)..Nevertheless I do skim through them looking for the info I need, but still not understanding how the system interprets the f from -f in ps -af.. I appreciate your response however i'm one step closer to understanding how this all works
Last edited by linux4evr5581; 12-28-2016 at 08:03 PM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.