I usually use some common commands to add to favorites. 1. I use Xshell client to upload local files/download files. It seems like this is common. Www.2cto.com 2. scp fileNanme 10. XX:/home/username: copy the uploaded file to the specified directory. This is used in multi-server copy. 3. less/home/user/xxx. xml is a basic command to quickly view files in the text format. I will mark it here to avoid forgetting it. 4. jar-cvfM0 name. war. /package all files in the current directory into name. war 5, jar-xvf game. decompress war to the current directory 6, bin/startup. sh; tail-f logs/catalina. start Tomcat and display logs 7. ps-ef | grep tomcat query the currently running process named tomcat 9. Use the public key to log on to the remote server to generate a key: ssh-keygen-t rsa copy Public Key: Method 1: scp ~ /. Ssh/id_rsa.pub 10. XX :~ /. Ssh/authorized_keys Method 2: ssh-copy-id-I ~ /. Ssh/id_rsa.pub 10. XX. XX. XX 10. Reverse query DNS Linux: host IP Windows: nsloopup IP 11 based on IP address. decommission package: Package: files or directories packed in tar-jcv-f XXX.tar.bz2: tar-jxv-f XXX.tar.bz2-C decompressed directory package: tar zcvf * .tar.gz XXX unpack: tar zxvf * .tar.gz 12, database backup: mysqldump db_wis>/home/username/db_backup/db_back201211_1028. SQL mysqldump-h10.XX. XX. XX-uusername-ppassword databasename>/home/username/db_backup/db_back201211_1028. SQL 13, MyS QL command: create user 'username' @ 'host' identified by 'Password'; authorized USER: GRANT privileges ON databasename. tablename TO 'username' @ 'host' cancel authorization: REVOKE all ON *. * FROM 'username' @ 'host'; 14, jar package run related: java-cp classes: lib/c3p0-0.9.1.2.jar: lib/log4j-1.2.16.jar: lib/dom4j-1.6.1.jar: lib/mysql-connector-java-5.1.21-bin.jar: lib/fastjson-1.1.22.jar com. XX. XX. service. XXClass 15. find files that contain certain characters. -name *. xml | xa The rgs grep 'ls | xargs grep' keyword 'is suitable for filtering large amounts of data.