Common commands for Linux VPS novices

Common commands for Linux VPS novices

For novices only, veterans please don’t read this!
With these commands, there is basically no problem using a VPS, that's what I do :)

【cd】
The cd command not only displays the current status, but also changes the current status. The cd in Linux is similar to that in DOS.
#cd /home/wwwroot (enter the /home/wwwroot directory)
#cd .. (enter the previous directory)
#cd – (Enter the last directory entered)
#cd / (enter the root directory)
【tar】
The tar command is commonly used in the packaging, backup and decompression process in VPS.
#tar cvf a.tar.gz *.* (Pack all files in the current directory and compress them into a.tar.gz file)
#tar cvf a.tar.gz /home (pack all files in the home folder and compress them into the file name a.tar.gz)
#tar xvf a.tar.gz (decompress a.tar.gz to the current folder, you can also use zxvf)
#tar tvf a.tar.gz (browse the files in the a.tar.gz compressed package)
【rm】
rm is the delete command in Linux.
#rm a.tar.gz (delete a.tar.gz, then a confirmation message will appear, enter y)
#rm –r (delete directories one by one and confirm)
#rm –rf (forced deletion, no confirmation)
【ls】
ls is equivalent to dir in DOS command, which lists the files in the current directory. (Note: dir can also be used in Linux)
#ls (list directory files)
#ls –l (list files and display detailed information)
#ls -l |more (too many directories to display on split screen)
【mv】
mv is the same as move, but it also has the function of renaming.
#mv a.tar.gz /home (move a.tar.gz in the current directory to the home directory)
#mv a.tar.gz b.tar.gz (rename a.tar.gz to b.tar.gz)
【cp】
The full name of cp is copy, which naturally means copy.
#cp a.tar.g /home (Copy a.tar.gz in the directory to the home directory. You can select multiple files at a time. Just add the file name after cp)
#cp –R (copy the entire directory, including subdirectories)
Other commands
#mkdir (create directory)
#su (Switch User)
#pwd (display the user's current directory)
#wget (download from source file)
#ftp (Connect to FTP)
#passwd (Change password)
#reboot (reboot)
#restart (*Also means restart, e.g. /lnmp/root restart)

<<:  Ge.tt - A free real-time file sharing website

>>:  Google Doc file synchronization and backup software [Syncdocs]

Recommend

Enotch Networks: IT service provider offering a full range of hosts

Enotch Networks, Inc provides virtual hosting, VP...

ITEFG 2GB RAM SSD Hard Drive German LXC VPS Review

Details: ITEFG: €3.98/half year/2GB memory/20GB S...

BlueHost host opens Mysql database remote connection

We know that most of the current virtual hosts...

Understanding of Google PR and Baidu weight

In Aiba’s understanding, Baidu weight and Google ...

LeaseWeb: €3/month/1GB RAM/40GB storage/4TB bandwidth/KVM/USA

LeaseWeb, a Dutch hosting provider, was founded i...

DogYun: Hong Kong GIA KVM VPS, pay by the hour, 10Mbps bandwidth, 30% discount

DogYun, a Chinese merchant, mainly provides KVM V...

SparkVPS: $25/year/2G memory/20GB SSD space/2TB traffic/KVM/Los Angeles

SparkVPS, a foreign hosting provider, has been in...