linux-Common Commands (3) file Search command

Source: Internet
Author: User

File Search command: Find

Command name: Find

Command location:/bin/find

Execute Permissions: All Users

Function Description: File search

Syntax: Find [Search Range] [match condition]

$ fimd/etc-name Init

Find file init in directory/etc

-iname Case insensitive

$ find/-size +204800

Find files larger than 100MB in the root directory

+n greater than-n less than n equals

$ find/home-user Somnus

Find files with owner Somnus in the/home directory

-group according to the group.

$ find/etc-cmin-5

Find files and directories with properties modified within 5 minutes under/etc

-amin Accessing Time Access

-cmin file attribute Change

-nmin File Contents Modify

----------------------------------------------------------------------------------

File Search command: which

Command name: which

Command location:/usr/bin/which

Execute Permissions: All Users

Function Description: Search the directory of the command and alias information

Syntax: which command

Example: $ which LS

----------------------------------------------------------------------------------

File Search command: Whereis

Command name: Whereis

Command location:/usr/bin/Whereis

Execute Permissions: All Users

Function Description: Search for the command directory and help document path

Syntax:whereis [command name]

Example: $ whereisls

----------------------------------------------------------------------------------

File Search command: grep

Command name: grep

Command location:/bin/grep

Execute Permissions: All Users

Function Description: Searches the file for string matching lines and outputs

-I is case insensitive

-V excludes the specified string

Syntax: grep-iv[specified string] [file]

Example: $ grep mysql/root/install.log

----------------------------------------------------------------------------------

Help command: Man

Command name: Man

Command English original meaning: manual

Command location:/usr/bin/Manual

Execute Permissions: All Users

Function Description: Get help information

Syntax: Man [command or configuration file]

----------------------------------------------------------------------------------

Help commands:

Command name: Man

Command path: Shell built-in commands

Execute Permissions: All Users

Function Description: Get help for Shell built-in commands

Syntax: Man [command




linux-Common Commands (3) file Search command

Related Article

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.