Linux 2

Linux operating system

 

1.alias setting alias

 

2.Unalias cancels alias

 

3.Date View Date and Time – Signification Date and Time

 

4.cal View Calendar

 

5.ntpdate Time Synchronization – U Cross Firewall CN.Pool.ntp.org

 

6.cat -n = NL Sort

 

7.TAC reverse sort

 

8.REV, for example 12345-> 54321

 

9.more shows a lot

 

10.less Due to more than More can’t go back, take more antonym LESS plus post-refundable function.

 

11.Head defaults to see the first 10 lines of the command (head -8 a.txt | tail -4 this command is 5-8 line content)

 

12.tail from the next future

 

13.WC effect: Word count in statistics: WC [Options] …. [File]

Common options:

-L: Statistics

-W: Statistical words

-c: Count the number of bytes

 

14.*grep

Role: Find and display lines that contain specified strings
Usage: grep [option] … pattern [file] …
-i: ignore the case when looking up
-v: Reverse lookup, output and conditions do not match
-E: Support regular expressions when looking up
-W: Treat conditions as intact words when looking up
“^…”表示以…开头
“… $” means
“^ $” Means a blank line

15.”egrep
Role: Enhanced Filter (GREP-E)
Format: EGREP [Options] “Find Conditions 1 | Find Conditions 2 | Find Conditions 3 ..” Target File

 

16.gzip

Role: Compression, digital control compression level of 1-9, the larger the number, the higher the compression level. After the compression file format is “.gz”
Format: Gzip [-9] file name


17.gunzip
Role: Unzip the compression file for .gz.
Format: Gunzip file name


18.bzip2

Role: Compression, digital control of the option 1-9, the higher the number, the higher the compression level. After the compression file format is “.bz2”

 

19. bunzip2

Role: Decompressing the compression file of .bz2
Format: Bunzip2 file name


20. · Tar
Role: Produce archived files, release archive
Format:
Archive: TAR [Option C …] Archive file name source file or directory release: tar [option x ·] Archive file name C target directory]

Common options:
-c Create a .tar format package file
-X unwounded. Tar format package file
-f means using archived files (behind the file name)

-z Call the Gzip program to compress or decompress
-J Call the BZIP2 program for compression or decompression
​​Note:
1. You can omit “-2” or “-j” when you decompress, you can identify yourself when you decompress.
2, TAR command When you create a packaging compressed file via the -zcf option (.tar.gz = .tgz)

-C Unpacking the target directory specified when the release