In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
1 、 ln--link
Meaning: create a linked file
Format: ln [- s] source file... link file path
Add a symbolic link with the-s (create soft connection) option to point to the path of the original file
Note: the source file must be an absolute path equivalent to a "shortcut", also known as a soft connection.
2. Search tool which search tool
Format: which [- a] program name.
Whereis search tool
Format: whereis file name
Set up a location index library and execute the updatedb command (manually generate the database) default location: / var/lib/mlocate/mlocate.db
3. Locate positioning tool format: locate [options]... keyword common command options:
-I: ignore case when looking up
-r: use regular expressions when looking up
4. Find search tool format: find [look in] [search criteria] commonly used search criteria
-type: find by file type
F: ordinary files
D: directory
L: connect the file
B: block device file
C: character device file
-name: find by file name
-a: multiple conditions need to be met at the same time
-o: multiple conditions satisfy any one of them
-size: find by file size
-mtime: find other search criteria by file modification time
-user: search by the user to which the file belongs
-perm: search the permissions of the file
-axdepth: specify the directory depth to look up
/ / find all directories under directory / boot/
/ / find all the ordinary files under the directory / boot/
/ / find the file named tty1/tty2/tty3 under the directory / dev/
/ / find files larger than 2m under the directory / boot/
/ / find the files under the directory / boot/ whose names have begun with vm
Processing the file format found by find: find [range] [condition]-exec processing command {}\
Note: {}: replace each search result,\;: end of processing operation
/ / find all files larger than 2m under the directory / boot/ and display them in a long format
/ / find all files larger than 10m under the directory / boot/ and copy them to the directory / opt/
5 、 cat-Concatenate
Meaning: display file content format: cat [options] File name Common command options:
-n: displays the line number before each line (including blank lines)
/ / View the display information of the network card (display line number).
6. Intercept the head / tail of a file
Head, tail command
Format: head-n file name
Tail-n file name
Note: head/tail displays the first / last ten lines by default
/ / File / etx/passwd displays the first ten lines
/ / File / etx/passwd displays the last ten lines
/ / File / etx/passwd displays the first two lines (either of the following two representations is OK)
7 、 wc-Word Count
Meaning: digital statistics format of files: wc [options] File names Common Command options
-l: calculates the total number of lines of text
-w: count the number of words
-c: calculate the number of bytes in the file
-m: count the number of characters
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.