Whether you’re new to Linux or just need a quick refresher, this cheat sheet will help you master the most essential Linux commands . Perfect for beginners, sysadmins, and developers alike!
๐ File & Directory Commands
Command Description lsList files in a directory ls -laLong list including hidden files cd folder_nameChange directory pwdShow current directory mkdir folder_nameCreate new folder rm file.txtDelete file rm -r folderDelete folder and contents cp file1 file2Copy file1 to file2 mv old newRename or move a file or folder
๐ File Viewing & Editing
Command Description cat file.txtDisplay file contents less file.txtView large file with navigation head -n 10 file.txtShow first 10 lines tail -n 10 file.txtShow last 10 lines nano file.txtEdit file in terminal (simple editor) vim file.txtEdit file using Vim (advanced)
๐ Searching & Finding
Command Description find / -name file.txtSearch file system for file.txt grep "text" file.txtSearch for “text” in file grep -r "text" /pathRecursive grep in directory
๐ Permissions & Ownership
Command Description chmod 755 fileChange file permissions chown user:group fileChange file ownership ls -lView permissions and ownership
๐ง System Info
Command Description uname -aSystem info topReal-time system processes df -hDisk space usage free -mRAM usage uptimeSystem uptime
๐งช Package Management
๐ข Debian/Ubuntu (APT)
bashCopyEditsudo apt update
sudo apt upgrade
sudo apt install package_name
๐ต RHEL/CentOS (YUM/DNF)
bashCopyEditsudo yum update
sudo yum install package_name
๐ Networking Commands
Command Description ip a or ifconfigShow IP addresses ping google.comTest connectivity curl example.comFetch webpage netstat -tulnShow listening ports
๐ฆ Archiving & Compression
Command Description tar -czvf archive.tar.gz folderCompress folder tar -xzvf archive.tar.gzExtract archive zip file.zip file.txtZip a file unzip file.zipUnzip a file
๐๏ธ Bonus Tips
Use tab to auto-complete commands or filenames
Use history to see recently used commands
Press Ctrl + C to cancel a running command
Use !! to run the last command again
Use man command for help with any command
๐ง Pro Tip: Save This as a PDF!
Press the below link and save this page as a PDF for offline access or keep it pinned for daily use.
https://prashanthbachewal.in/wp-content/uploads/2025/06/Linux_Commands_Cheat_Sheet_2025.pdf
๐ฌ Conclusion
Linux might look intimidating at first, but once you get used to the command line, it becomes a superpower. Bookmark this cheat sheet and practice daily to become more efficient and confident using Linux.
๐ก Want more Linux tutorials? [Subscribe to our newsletter] or [Check out our Linux Basics series].
VIDEO
Leave a Reply