cancel
Showing results for 
Search instead for 
Did you mean: 
Chetan_Tiwary_
Community Manager
Community Manager
  • 8,295 Views

100 Essential Linux Commands: A Comprehensive Guide

User Management

  1. useradd: Create a new user account.
  2. userdel: Delete a user account.
  3. usermod: Modify user account information.
  4. passwd: Change a user's password.
  5. groupadd: Add a new group.
  6. groupdel: Delete a group.
  7. groupmod: Modify group information.
  8. id: Print user and group information.
  9. su: Switch user.
  10. sudo: Execute commands with elevated privileges.

File and Directory Management

  1. ls: List directory contents.
  2. cd: Change directory.
  3. pwd: Print working directory.
  4. mkdir: Create a directory.
  5. rmdir: Remove an empty directory.
  6. rm: Remove files or directories.
  7. cp: Copy files or directories.
  8. mv: Move or rename files and directories.
  9. touch: Update file timestamps.
  10. chmod: Change file permissions.
  11. chown: Change file ownership.
  12. chattr: Change file attributes.
  13. ln: Create symbolic links.
  14. find: Find files based on criteria.
  15. locate: Find files using a database.
  16. grep: Search for patterns in files.
  17. sed: Stream editor for text manipulation.
  18. awk: Text processing language.
  19. cut: Extract columns from text.
  20. paste: Merge lines of text files.
  21. sort: Sort lines of text.
  22. uniq: Filter out repeated lines.
  23. wc: Count words, lines, and characters in a file.
  24. diff: Compare files line by line.
  25. patch: Apply patches to files.
  26. head: Display the first few lines of a file.
  27. tail: Display the last few lines of a file.
  28. less: View files one page at a time.
  29. more: Similar to less, but with fewer features.
  30. cat: Concatenate and display files.
  31. tac: Concatenate and display files in reverse order.

Text Editing

  1. vi/vim: Powerful text editor.
  2. nano: Simple text editor.
  3. emacs: Advanced text editor.

System Information and Monitoring

  1. top: Display system processes.
  2. htop: Interactive process viewer.
  3. vmstat: Show system memory, processes, interrupts, paging, block I/O, and CPU info.
  4. mpstat: Monitor per-processor statistics.
  5. iostat: Monitor block I/O statistics.
  6. netstat: Show network statistics.
  7. ifconfig: Configure network interfaces.
  8. ip: Advanced network configuration tool.
  9. ss: Show socket statistics.
  10. lsof: List open files.
  11. free: Display system memory usage.
  12. df: Display disk usage.
  13. du: Estimate disk space usage.
  14. uptime: Show system uptime and load average.
  15. date: Display or set system date and time.
  16. cal: Display a calendar.

System Administration

  1. lspci:  List all PCI devices.
  2. lsusb: List USB devices.
  3. passwd: Change passwords.
  4. systemctl: Control systemd services.
  5. journalctl: View systemd journal logs.
  6. crontab: Schedule tasks to run periodically.
  7. at: Schedule one-time commands to run at a specific time.
  8. dmesg: Print kernel ring buffer.
  9. mkfs: Create a filesystem.
  10. fsck: Check and repair a filesystem.
  11. mount: Mount a filesystem.
  12. umount: Unmount a filesystem.
  13. fdisk: Partition disk drives.
  14. parted: Partition disk drives (more advanced).
  15. blkid: Print block device information.
  16. dd: Copy and convert files.
  17. tar: Archive and compress files.
  18. gzip/gunzip: Compress and decompress files.
  19. bzip2/bunzip2: Another compression utility.
  20. xz/unxz: Another compression utility.
  21. zip/unzip: Zip and unzip files.
  22. unrar: Extract RAR archives.
  23. 7z: 7-Zip file archiver.
  24. screen: Terminal multiplexer.
  25. tmux: Terminal multiplexer.
  26. nohup: Run commands in the background.
  27. nice/renice: Change process priority.
  28. sleep: Pause execution for a specified time.
  29. wait: Wait for background jobs to finish.
  30. kill: Send signals to processes.
  31. killall: Kill all processes matching a name.
  32. pkill: Kill processes based on a pattern.
  33. bg: Send a job to the background.
  34. fg: Bring a job to the foreground.
  35. jobs: List background jobs.
  36. nc: Netcat, a network utility for reading from and writing to network connections.
  37. ping: Check network connectivity.
  38. traceroute: Trace the route packets take to a destination.
  39. nslookup: Query Domain Name System (DNS) servers.
  40. dig: DNS lookup utility.
4 Replies
Leon120
Mission Specialist
Mission Specialist
  • 8,258 Views

Thank You
Chetan_Tiwary_
Community Manager
Community Manager
  • 154 Views

Adding 30 advanced but useful Linux commands to this popular cheat sheet :

  1. xargs – Build and execute commands from standard input (eg: pipe find results into other commands).

  2. watch – Run a command repeatedly and display its changing output over time.

  3. alias – Create a shortcut for a longer command.

  4. unalias – Remove a previously defined alias.

  5. whereis – Locate the binary, source and manual page for a command.

  6. strace – Trace system calls and signals used by a process (good for debugging).

  7. jq – Process JSON data on the command line.

  8. tcpdump – Capture and display network packets for troubleshooting network issues.

  9. iftop – Monitor real-time bandwidth usage per interface/host.

  10. rsync – Sync files/directories locally or over network (efficient for backups).

  11. umask – Set default file creation permissions for new files/directories.

  12. chroot – Change the root directory for a process (useful for rescue & isolation).

  13. trap – Define shell script actions when signals are received (for cleanup, etc).

  14. tee – Read from standard input and write to standard output and to files.

  15. disown – Remove a job from shell’s job-control so it won’t receive SIGHUP after logout.

  16. env – Run a command in a modified environment or display environment variables.

  17. export – Set environment variables for current session or children processes.

  18. unset – Remove environment variables from current shell.

  19. sysctl – Modify kernel parameters at runtime.

  20. xfs_growfs / resize2fs / lvextend – Expand filesystems or LVM volumes online (depending on file system type).

  21. lsof +D <dir> – List open files under a directory tree (helps find what’s blocking unmount, etc).

  22. ncdu – Interactive disk usage explorer (useful on head-less servers).

  23. vgdisplay / pvdisplay / lvdisplay – Display LVM volume group / physical volume / logical volume details.

  24. ss -tunlp – Show listening sockets with process names (modern replacement/enhancement for netstat).

  25. nmcli – Command-line tool to manage network settings via NetworkManager.

  26. hdparm – Show or set SATA/IDE drive parameters (for hardware/IO tuning).

  27. smartctl – Monitor SMART status of drives (for early detection of disk failure).

  28. pgrep: Pattern match to find process IDs

  29. apropos – Search the manual page names & descriptions for keywords.
  30. ipcrm – Remove System V interprocess communication objects (shared memory, message queues, semaphores).

 

Blue_bird
Starfighter Starfighter
Starfighter
  • 143 Views

Great Information..!

Thanks for sharing..! @Chetan_Tiwary_ 

Chetan_Tiwary_
Community Manager
Community Manager
  • 92 Views

glad that it is useful @Blue_bird !

0 Kudos
Join the discussion
You must log in to join this conversation.