Turn from: http://www.kuqin.com/linux/20091009/70532.html
Recently, I was learning Linux, here are some notes.
When you use a computer, you often need to find files.
There are many ways to do this in Linux. Foreign website Linuxhaxor summed up five commands, you can see yourself know a few. Most programmers, who are likely to use 2 to 3 of them frequently, have few people who are familiar with these 5 commands
Locate Inittab Find name contains all the information of Inittab (fast search, in fact it is a search for Linux repositories, which is different from find in a partition of a disk or a directory)Locate Locate.db Search Linux repositoriestouch/tmp/meinv /tmp-name MEINV can find the results of MEINVtouch/root//root-name MEINV found MEINV file updatedb Manual upd
Analysis of five search commands in Linux
When using a computer, you often need to find files. In Linux, there are many ways to do this.
1. find (slow hard disk search)
Find is the most common and powerful search command. You can use it to find any file you want.
The format of find is as follows:
$ Find
-
-
-
If no
Three search commands in linux
There are many commands in linux to view the file path. Here we will summarize them a little.
1. find command
The find command should be the most familiar SEARCH Command and the most powerful search command in linux. It can find any file you
Summary
There are 5 main file lookup commands in Linux: Find, locate, Whereis, which, type.Find is the most powerful, but time-consuming.Locate can be seen as a compact version of Find, but it's very fast.The use of Whereis, which and type is small and has special uses.
Find
Find is the most common and powerful search command that you can use to find any file.Use format for find:Find
which
If nothing i
Find/etc-name init Search all files under the ETC directory with the file name init (exact search)Find/etc-name *init* Search etc directory The file name below contains all files for init (fuzzy search), Init*,init??? (* denotes any character,?) Represents a character), the file name is case-sensitivetouch/etc//etc-n
Detailed description of grep, egrep, and fgrep usage of text search commands
I. Learning Objectives
Understand and be familiar with grep, egrep, and fgrep commands.
Ii. Learning Content
1. Meaning and usage format of grep, egrep, and fgrep commands:
Grep: a command that uses the mode defined by the basic regular expre
Locate and find: two command for searching files: this command requires the database indexed in the background as the support when running. in Ubuntu, this database file is located in varcachelocatelocatedb. In general, this database file is automatically updated by cron every day through the locate and find: two search file commands locate: this command requires the database to be indexed in the background
More/etc/inittab Paging View Inittab file contentsgrep multiuser/etc/inittab Find the location of the multiuser string in Inittab file contentsGrep-i Multiuser/etc/inittab Find the multiuser string in the location of the Inittab file contents (ignoring case)Grep-v ^#/etc/inittab View the contents of the Inittab file, but not all line information (#表示注释) that begins with the # sign, that is, the content of the file that is viewed inittab the contents of the file, but does not contain commen
How can Mysql use commands to achieve hierarchical search help?
Preface
This article mainly introduced to you the Mysql use command classification to find help related content, this article sample branch version MariaDB-10.1.19 Based on msql, share for your reference to learn, below not much to say, let's take a look at the detailed introduction:
Query all help
If you want to know what mysql can do for us,
Common Windows application software commands:1. Regedit: Open Registry Editor2. Control: Open the Dashboard3. Msconfig: Open System Configuration4. Gpedit.msc: Open Local Group Policy5. Explorer: Open Explorer6. Taskmgr: Task Manager7, Logoff: Direct logoff computer8. OSK: Open on-Screen keyboard9. Calc: Open Calculator10, MSPaint: Pull out the drawing software11. DxDiag: View Computer Configuration details12. MSTSC: Open Remote Desktop Connection13.
Which, which means, is to search for the location of the command and the command alias from the path specified by the PATH environment variable.which command features:1"which" 命令只能查找系统命令,不能搜索普通文件。2"which" 命令是从PATH环境变量指定的路径中,搜索某个系统命令的位置, 并且返回第一个搜索结果。PATH environment variable:PATH:决定了shell将到哪些目录中寻找命令或程序,PATH的值是一系列目录,用":"隔开,当您运行一个命令时,Linux在这些目录下进行搜寻编译链接。The which command differs from the Whereis command:1"whereis" 命令查询的是命令位置和帮助文档的位置; "which" 命令查询的是命
1. File Search Command Locate2. Command Search command which and Whereis3. File Search command Find4. String Search command grep5. The difference between find and grepLocate + file nameLocate search is in the background database by file name
Which CP find the location of the CP command (by finding The result/BIN/CP can tell us that CP is a command that all users can use) which useradd find the location of the Useradd command (by finding the result /usr/sbin/useradd 's location can tell us that useradd can only be used by super users.Which RM can not only find the RM command location, but also get the RM command alias "Rm-i"rm/tmp/ABCD Delete tmp directory of ABCD file, there will be prompted to confirm the deletion of/BIN/RM/TMP/AB
(Find the directory under the/tmp/folder)find/tmp/-type F (find files under the/tmp/folder)find/tmp/-type b (Find block devices under the/tmp/folder)find/tmp/-type C (Find character devices under the/tmp/folder)find/tmp/-type S (Locate the socket under the/tmp/folder)find/tmp/-mtime-10 (Create/modify all files within 10 days)find/tmp/-mmin-10 ( Create/Modify all files in less than 10 minutes )find/tmp/-atime-10 (all files with read/execute time within 10 minutes)find/tmp/-ctime-10 (modify fi
1.find[[email protected] tem]# find/etc-name init* (full wildcard)[Email protected] tem]# find/etc-name init??? (Single wildcard character)/etc/inittab(Case sensitive)-iname (case insensitive);[Email protected] tem]# find/etc-name init???/etc/inittab[Email protected] tem]# find/etc-iname init???/etc/inittab/etc/inittab(Note: Server peaks cannot be found with find, the more accurate the better!) )2.Linux Fundamentals and Applications tutorial 004 (Simple basics of File
is located and the Help document path , where the path is/usr/bin/whereis, in the syntax format:Whereis [command name]To find the command information for LS:[Email protected] ~]# Whereis Lsls:/bin/ls/usr/share/man/man1/ls.1.gz/usr/share/man/man1p/ls.1p.gz(5) grepThe grep command is used to search the file for string-matched rows and outputs , where the path is/bin/grep, with the syntax in the following format:Grep–iv [Specify string] [file]where the-
There are many ways to do this in Linux. Foreign website Linuxhaxor summed up five commands, you can see yourself know a few. Most programmers, who are likely to use 2 to 3 of them frequently, have few people who are familiar with these 5 commands.
nd
Find is the most common and powerful search command you can use to find any file you're looking for.
Find uses th
File Search Related commands1:locate commandRequires Yum install MlocateLocate file name Search by file name in the background database, search faster /var/lib/mlocate#locate命令所搜索的后台数据库UpdateDBUpdate Database/etc/updatedb.conf configuration filePrune_bind_mounts= "Yes"#开启搜索限制prunefs=#搜索时, non-searchable file systemprunenames=#搜索时, do not
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.