Which commands are commonly used in CentOS6.5?
CentOS6.5 commonly used commands refer to which, many novices are not very clear about this, in order to help you solve this problem, the following editor will explain for you in detail, people with this need can come to learn, I hope you can gain something.
-- Home directory
Root / root
Oracle / home/oracle
Cd: switch the home of the current directory
Cd -: switch to the last directory
Cd.. /: go back to the directory above
-- Catalog viewing and
Ls: print the folder and file names of the current directory
Ll-l = = "ll (set by alias) View folder name, term, date
Ll-a: view hidden folders and files already. The beginning
Ll-h: size of the file (du-sh)
Ll-rt: sort by time
-- File editing
Vi: edit file command (vim)
Vi xxx.log
I key edit mode, add delete file content
Esc key command mode
Shift+ colon key trailing mode
Wq and x save exit in trailing mode (! Mandatory)
Q does not save exit in trailing mode
In Vi (deepening) command mode:
Dd deletes the current line
DG deletes all lines below the cursor
Gg jumps to the first line and the first character
G jumps the first character of the last line
0 the beginning of the line
Shift+$ end of line
Shift+an end of line and edit
Yy replication
P paste
U return
In Vi (deepening) trailing mode:
: / content enter n to look down, N to find up
: set nu displays the line number
Set nonu cancels the display of line number
10 enter the line that jumps:
Empty a file:
Echo'> xxx.log
Cat / dev/null > xxx.log
Vi: gg > dG
Delete a file:
Delete directory: rmdir empty directory (remove)
Rm-rf test.txt (- r for recursion,-f for mandatory)
Is it helpful for you to read the above content? If you want to know more about the relevant knowledge or read more related articles, please follow the industry information channel, thank you for your support.