Common Linux commands-file search command find, common linux commands

Source: Internet
Author: User

Common Linux commands-file search command find, common linux commands

Command name: find
Command path:/bin/find
Syntax: find [search range] [matching condition]
Function Description: file search

Example
Find/etc-name init
Find the file init In the/etc directory
-Iname is case insensitive.
* Represents a wildcard? Represents a character

Find/-size + 204800
Search for files larger than MB in the root directory
+ N greater than-n Less than n equal

Find/home-user shenchao
In the home directory, find the file whose owner is shenchao.
-Group: search by group

Find/etc-cmin-5
Search for the files and directories of attributes modified within 5 minutes under/etc.
-Amin access time
-Cmin file attribute change
-Modify the mmin File Content

Find/etc-size + 163840-a-size-204800
Search for files larger than 80 MB and smaller than MB in etc
-A: both conditions are met.
-O: only one sub-database can be connected to one sub-database.

Find/etc-name init-exec ls-l {}\;
Search for the init file ice under etc to display its details
-Exec/-OK command {}\; perform operations on search results

-Type: search by file type
F File d directory l soft connection file

-Inum search by I Node

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.