Top 10 most useful Linux commands
In this post, I list some of the most basic but most useful Linux commands for Linux novices. You can type these commands to manage your server. These commands are the easiest for beginners learning VPS or Linux server management.
- list command
ls -a
ls -l
ls -l | more
- Extract the tar.gz file
tar -xzf filename.tar.gz - Install the package
yum install package_name // for Centos and Redhat
apt-get install package_name// for Debian/Ubuntu - Viewing memory info
top
free
-
View disk usage
df -h - view the running process
ps aux
-
Delete all files in the folder
rm -rf /path - Edit files
nano /file_path - Change permissions and ownership
chmod -R 755 /folder_path
chown pbu /file_name
chgrp mygrp /file_name - View open ports
netstat -nap –tcp