1, the path plus the file name search (find):
Find a file name for the init etc directory.
Plus a wildcard after fuzzy search, as long as the file name can contain init.
Etc directory to find the beginning of the seven init file name.
2, case insensitive (-iname) search
We know that in windows system, the file names are case-insensitive, uppercase and lowercase are the same file. But in linux system, file names are case-sensitive.
When command find, is case-sensitive, how not case sensitive when searching for it?
Iname can use the command:
INITTAB first create a file in the etc directory:
Search files -iname command:
As can be seen from the search results, file names are case-insensitive.
3, depending on the file size of the search (-size):
A block of data bytes is equal to 0.5, so fast database 2048 is equal to 100M.
--204 800: The file size is less than 100M
+204800: The file size is greater than 100M
204800: The file size is equal to 100M
Search greater than 100M of files:
4, according to the owner to find:
Find all files of users zhang:
5. Find time attribute:
(1) -amin (to be accessed):
(2) -cmin (attribute change file):
(3) -mmin (modify the contents of the file):
6, the connecting operation command:
-a: two conditions are met.
-o: one of two conditions are satisfied.
-type: Find file type: f: file, d: directory, l: soft link file
(1) Find the beginning to init file directory and type:
(2) find the results of a query operation:
(1) -exec: the first is not case-sensitive file query file inittab file, then check its details to the file query:
(2)-ok:
The difference is that with the -exec, -ok results will operate, but the operation will be carried out before the inquiry.
7. i node query (file name suitable for the more complex cases):
i node (1) to view the file or directory:
(2) Find the node i values of files or directories 4:
Query node values corresponding to the file and view its details: