๐Ÿง Linux Commands Cheat Sheet for Beginners (2025 Edition)

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

CommandDescription
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

CommandDescription
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

CommandDescription
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

CommandDescription
chmod 755 fileChange file permissions
chown user:group fileChange file ownership
ls -lView permissions and ownership

๐Ÿ”ง System Info

CommandDescription
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

CommandDescription
ip a or ifconfigShow IP addresses
ping google.comTest connectivity
curl example.comFetch webpage
netstat -tulnShow listening ports

๐Ÿ“ฆ Archiving & Compression

CommandDescription
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].

Leave a Reply

Discover more from Prashanth Bachewal

Subscribe now to keep reading and get access to the full archive.

Continue reading