*
When landing root And @ There is no space between

*
mv Command to cut , Change file name and other functions

*
cp command -i The command asks before overwriting

*
cat Press enter after obtaining from the keyboard to display on the screen , Read small files

*
tac And cat corresponding Reverse order printing

*
more command Display for easy reading

*
| The Conduit

*
dmesg Print log

*
grep filter

dmesg | grep err |more -3 Combination of commands

*
journal

*
echo Print -e( Show special characters ) redirect (>)

*
“>” redirect ">>" Append redirection , Write from end of file , Historical data will be saved

*
“<” input redirection

*
less And more Functional similarity /+ Digital search

-N set number q Can stop

*
head Get the first ten lines of the document You can also specify how many lines to get in front

*
tail Get the last ten lines of the document You can also specify how many rows to get

*
Get time date

Format printable time

time stamp date+%s (1970/1/1 Number of seconds from zero to now Zero here is equivalent to eight o'clock Beijing time )
date +%Y/%m/%d+%H:%M:%S It can be transformed into understandable time

date -d@ Timestamp conversion (@0 Is the time when the timestamp starts The time difference is eight hours )

*
cal Calendar instruction

*
grep Text line filter tool Facilitate text processing

grep -E regular expression
​ -v Reverse selection ( be similar to C Logical non in language )
​ -i ignore case
​ -n Output line number

grep With printing function

*
find Disk discovery command High cost of discovery

*
which Specifically find the path where the command is located

whereis As long as the keywords are included, they will be found ( No spaces )

*
alias ls -l And ll
ls -l --color=auto Alias is ll
Put it another way :ll yes ls -l Alias with specific options
alias Custom alias as alias lll=‘ls -l -i --color=auto’ (color It's for coloring )
Cancel alias : Turn off the terminal and it's gone Or set to null

*
Packing compression , Unpack

zip pack :
​ zip xx.zip xx
​ Packaged zip The file is in the current directory by default
​ Use when packaging multiple directories -r ( Recursive )
unzip Unpack :
​ unzip xx.zip -d route
​ The unpacked files are in the current directory by default
​ -d Specify the extracted file path

tar:( There is no short bar connection between )
​ tar czf c establish z Compressed package f New name Create a compressed file with the extension tgz
​ tar cvzf Yes v The packaging process is displayed after
​ tar xzf x Unzip the package
​ tar xvzf Show unpacking process
​ tar xzf xx.zip -C route Unzip to the specified path

Reasons for packaging compression : Multiple files are packaged into one file , Reduce file loss due to network and other reasons ( pack ), You can also reduce the volume ( compress )

*
tree Tree display

*
bc Calculator Add other commands to control accuracy

*
uname -a View host name , Current machine version , Kernel name , Kernel version , Architecture and other information

*
ctrl+r stay XShell You can search the original command in the

*
history Displays all commands that have been tapped

*
Tab Key can be automatically supplemented ( Press twice to get a conditional command )

*
ctrl+c End process

*
ctrl+d amount to exit Press several times to exit the account /XShell

*
shutdown
-h Shut down immediately
-r Restart after service shutdown
-t sec How many seconds will it shut down

*
reboot restart

*
Sign in linux The system creates a process for the user Generally called bash( Command Line Interpreter )
user -> shell Shell -> linux kernel

*
What is? shell? Software layer wrapped outside the operating system It is also a command line interpreter

*
Why does it exist shell? Solve the problem that users are not good at dealing with the operating system Deliver requests and feedback Protected operating system

*
shell And bash Relationship between ?shell Is a class bash It's a concrete one ( Kind of like java Instantiation in )

*
jurisdiction : Super user (root) And ordinary users

*
Switch users su - ( Ordinary users -> Super user )

*
increase root Password security

*
su + user name Switch users

*
useradd ->sudo passwd user name ->userdel -r user name ( No -r Delete not clean The directory will be left )

*
sudo Temporarily increase permissions , Error reporting solution : configuration file , change /etc/sudoers File content in

Technology