LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Debian (https://www.linuxquestions.org/questions/debian-26/)
-   -   where is the find command located? (https://www.linuxquestions.org/questions/debian-26/where-is-the-find-command-located-685815/)

dave247 11-24-2008 03:24 PM

where is the find command located?
 
simple question: where is the find command located? I thought it was in the /bin directory with the other commands, but I do not see it.

My current find file is possibly corrupted so I want to replace it with a backed up one which I can trust.

Telemachos 11-24-2008 03:26 PM

Try the command which find. That should tell you where the command is (its full path).

sycamorex 11-24-2008 03:27 PM

Quote:

[xtd8865@localhost ~]$ which find
/usr/bin/find
Quoted from man which:
Quote:

which - shows the full path of (shell) commands.

dave247 11-24-2008 03:38 PM

Quote:

Originally Posted by Telemachos (Post 3353149)
Try the command which find. That should tell you where the command is (its full path).

yeah i tried that and it told me but i was sure if that was what I wanted or not.

How come some commands are stored in the /bin folder when others are in the /usr/bin folder?

jailbait 11-24-2008 04:06 PM

Quote:

Originally Posted by dave247 (Post 3353160)
How come some commands are stored in the /bin folder when others are in the /usr/bin folder?

It is pretty much up to the person who puts the distribution together.

---------------------
Steve Stites

Goce 11-24-2008 05:02 PM

FIND command at it's best!
 
Start a shell/terminal program or use CTRL-ALT-F1 and run the following;

if you are looking in your user folders;
find /home/user_name -name file_syntax*
Replace user_name with your login name and file_syntax with your search criteria.

If you need to find a system file or app;
sudo find / -name file_syntax*
You are using the find command as user root starting from / (root file system and all sub-folders) searching for the syntax of a app name ending with anything extra.

IE;
sudo find / -name ndiswrapper*
I'm looking for any file on the hard drive which startes with ndiswrapper and searching sub-folders too.

Hope this helps you out!



PS: If you did CTRL-ALT-F1, then you use CTRL-ALT-F7 to return to the graphical user interface. If you use a shell/terminal, you are allowed to copy from it as you are not in CTRL-ALT-F1.

AlucardZero 11-24-2008 10:10 PM

And that has what to do with the OP?

restless 11-25-2008 04:15 PM

another way to find out where a (executable) file is located is to use the 'whereis' command. This will also tell you the location of your file. but most of the time I think find should be in /bin

/usr/bin is commonly used by programs that aren't really needed to work properly with your shell

/sbin and /bin are the locations with the most common commands (like find, ls, grep, bash etc...)


All times are GMT -5. The time now is 04:09 AM.