Linux Find command

Source: Internet
Author: User

Which is the location of the lookup command, which is based on the user path path,

Locate is found in the database, and the database is updated as large as daily.
Whereis can find executable commands and man page
Find is finding files based on criteria.
which can find executable files and aliases (alias)

Which viewing the location of an executable file
Whereis viewing the location of a file
Locate to view file locations with a database
Find actual search hard disk query file name


1, which
Grammar:
[[email protected] ~]# which executable file name
For example:
[email protected] ~]# which passwd
/usr/bin/passwd
Which is to find the executable file through the PATH environment variable to that route, so the basic function is to find the executable file

2, Whereis
Grammar:
[[email protected] ~]# Whereis [-bmsu] file or directory name
Parameter description:
-B: Only binary files are found
-M: Only files found under the manual path of the description file
-S: Find source files only
-u: File without document description
For example:

Linux Find command

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.