mkdir usage
-P: Create a previous directory example of this directory: Mkdir-p a/b/c Create a C directory, but before the A and B directories, you need to use the-P command.
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/75/85/wKiom1Y7Fq_A66gfAAEPFU2g3l4575.jpg "title=" Mkdir-p.png "alt=" Wkiom1y7fq_a66gfaaepfu2g3l4575.jpg "/>
-V: Show detailed creation process
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/75/82/wKioL1Y7FtSS5lmIAABXBZfKCrE369.jpg "title=" Mkdir-v.png "alt=" Wkiol1y7ftss5lmiaabxbzfkcre369.jpg "/>
Use of LS (list)
-D: Directory
-L: Long format
-A: Displays so files (including hidden files.) )
-A: Show the files you own
CD (change dirctory) Switch Directory example: cd/etc/
Echo: Print content to interface example: echo "im start Linux Now" page output Im start Linux now
VI Editor
Input mode (ESC go to command mode) <===========> Command mode (press I,a to go to input mode)
The following command needs to be entered in command mode and preceded by: symbol
! : Force
Q (quit): Exit
W (write): Write
Cat View File Contents
Cat b.txt viewing file b.txt content
Cat >b.txt<<eof means to write AAA,BBB,CCC to B.txt.
>aaa
>bbb
>ccc
>eof
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/75/83/wKioL1Y7KWCgQ0ElAABDkW1MapY595.jpg "title=" Cat directed. png "alt=" wkiol1y7kwcgq0elaabdkw1mapy595.jpg "/> > Overwrite file contents >> append content at end of file
CP (copy) command
-R: Recursive replication
-P: Preserve the properties of the source file
-F: Forced overwrite, whether or not the file exists
-a=-pr
RM Delete command
-F: Force delete
-R: Recursive delete
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/75/86/wKiom1Y7JZCDu4iPAAE9lh2MRZs331.jpg "title=" Rm-rf.png "alt=" Wkiom1y7jzcdu4ipaae9lh2mrzs331.jpg "/>
RmDir can only delete empty directories (seldom used)
Head Select how many rows in front (default is 10 rows)
-n Example: head-30 a.txt | TAIL-11 Select 20-30 rows of data
Tail Select how many rows of data to start from the trailer
-N
grep filter rows (Core command)
-V: Filter Grep-v "AC" a.txt with AC line not shown
650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M02/75/87/wKioL1Y7asaiLtgTAABEdseC4k0839.jpg "title=" grep- V.png "alt=" Wkiol1y7asailtgtaabedsec4k0839.jpg "/>
Cat A.txt | Grep-v "AC"
SED filter Line
-N: List The contents of the following options
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/75/8A/wKiom1Y7cWDwCfboAABYld8nep8643.jpg "title=" Sed-n.png "alt=" wkiom1y7cwdwcfboaabyld8nep8643.jpg "/>p is printed meaning
-S: Replace
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/75/87/wKioL1Y7cqThqsYrAABKloZ6z0o010.jpg "title=" Sed-g.png "alt=" wkiol1y7cqthqsyraabkloz6z0o010.jpg "/>g replace all the meaning {the contents of the output change, the truth has not changed}
-I: Change the file (real content)
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/75/8A/wKiom1Y7c6vhRxy0AACqJU9DVm4718.jpg "title=" Sed-i.png "alt=" Wkiom1y7c6vhrxy0aacqju9dvm4718.jpg "/>
awk command
$: Qualifying Rows
awk ' {if (nr>19&&nr<31 print $)} ' Ett.txt
650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M02/75/AF/wKioL1ZAZuGSTqPKAAANC6afaF4493.png "title=" Awk.png "alt=" Wkiol1zazugstqpkaaanc6afaf4493.png "/>
-F: Specify input delimiter
$: Represents the first column
Awk-f ":" ' {print $} ' Ett.txt
650) this.width=650; "src=" Http://s5.51cto.com/wyfs02/M02/75/AF/wKioL1ZAaFPi_uqmAAATSmNcKTI295.png "title=" Awk-f.png "alt=" Wkiol1zaafpi_uqmaaatsmnckti295.png "/>
Alias aliases
Alias 1=ls
Unalias 1
650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M00/75/B1/wKiom1ZAaHjBb6YrAAAKCDAuviA010.png "title=" Alias.png "alt=" Wkiom1zaahjbb6yraaakcdauvia010.png "/>
Exiting the current login alias will expire, if you want to never expire, you need to add the following file
650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M01/75/AF/wKioL1ZAaeTAJEQ-AAHi4N5cLp0076.png "title=" Alias does not expire. png "alt=" Wkiol1zaaetajeq-aahi4n5clp0076.png "/>
Find Lookup command
Find/-type F-name "Ett.txt" Looking for ett.txt files
650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M02/75/B2/wKiom1ZAbZKhtXarAAAIjQZkFfo969.png "title=" Find.png "alt=" Wkiom1zabzkhtxaraaaijqzkffo969.png "/>
Xargs: Used to give the FIND/LS command to the back of the processing
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/75/B2/wKiom1ZAbfGxtVy8AAAFZPPtIqk199.png "title=" Xargs.png "alt=" Wkiom1zabfgxtvy8aaafzpptiqk199.png "/>
Installation of commands such as tree
650) this.width=650; "src=" Http://s4.51cto.com/wyfs02/M01/75/AF/wKioL1ZAbwnDgAP1AAAZvbRYfIY383.png "title=" Tree.png "alt=" Wkiol1zabwndgap1aaazvbryfiy383.png "/>
Linux Basic Command One