LINUX Commands - Cheat Sheet

LINUX Commands - Cheat Sheet for LINUX System Administrators

Jan 7, 2023 - 15:22
LINUX Commands - Cheat Sheet
LINUX Cheat Sheet

LINUX COMMAND CHEAT SHEET

90 Linux commands that Linux sysadmins and power Linux users regularly use.

1. ip - used to show or manipulate routing, devices, and tunnels.

2. ls - list the contents of a directory.

3. df - Displays the amount of disk space used.

4. du - display a list of all the files along with their respective sizes.

5. free - use to get a detailed report on the system's memory usage.

6. scp - securely copy files or directories over ssh.

7. find - locates files using user-defined criteria.

8. ncdu - provides a useful and convenient way to view disk usage.

9. pstree - used to show running processes in a tree (data structure).

10. latest - displays a list of the most recently logged-in people.

11. w – display a list of the currently logged-in user sessions.

12. grep - searches a file for a pattern of characters and displays all lines that match.

13. awk - a scripting language used for text processing.

14. sed - stream editor used to perform lots of functions on files, like searching, find and replace, insertion, or deletion.

15. cut - allows you to cut out sections of a specified file or piped data and print the result to standard output.

16. sort - used to sort files.

17. uniq - used to extract uniq occurences.

18. tr - utility for translating or deleting characters.

19. diff - used to display differences in files by comparing line by line.

20. uptime – displays the system uptime as well as the load average.

21. top – shows a real-time view of running processes in Linux.

22. vmstat - used to obtain information about memory, system processes, paging, interrupts, block I/O, disk, and CPU scheduling.

23. htop - a process viewer and manager that is interactive.

24. dstat - allows you to view all of your system resources instantly. All-in-one vmstat, iostat, netstat, and ifstat utility.

25. Iftop is a network traffic viewer.

26. nethogs - is a network traffic analyzer.

27. iotop - is an interactive I/O viewer. Get a snapshot of storage r/w activity.

28. iostat - provides statistics on storage I/O.

29. netstat -used to show network statistics.

30. ss - ss command is a simpler and faster version of the now obsolete netstat command.

31. atop – a tool for monitoring system resources in Linux.

32. ssh – secure protocol used as the primary means of connecting to Linux servers remotely.

33. sudo - run commands with administrative privileges.

34. cd – navigate between directories.

35. pwd – displays the current directory path.

36. cp - copy files and directories.

37. mv – move file or directories.

38. rm – deletes files and directories.

39. mkdir - create new directories.

40. touch – used to create, update a computer file or directory's access and modification dates.

41. man – used to read system reference manuals.

42. apropos – searches manual page names and descriptions for a user-supplied keyword.

43. rsync - remote file transfer and synchronization.

44. tar - is an archive utility.

45. gzip - use for compression and decompression of files.

46. b2zip - a compression utility comparable to gzip. It employs a distinct compression algorithm.

47. zip – used for file packaging and compression (archiving).

48. locate – in Linux, search for files.

49. ps – allows you to list the status of processes running on your system easily.

50. cron - execute scheduled tasks.

51. nmcli - sused to display network device status, create, edit, activate/deactivate, and delete network connections.

52. ping - sends an ICMP ECHO REQUEST to network hosts.

53. traceroute - examine the path packets follow to reach a specific host.

54. mtr - is a network diagnostic tool, a combination of ping and traceroute commands.

55. nslookup - interactively query Internet name servers (NS).

56. host –used for DNS (Domain Name System) lookup operations.

57. dig – DNS lookup tool.

58. wget - download files through HTTP, HTTPS, FTP, and FTPS.

59. curl – data transport via several network protocols. (Can handle more protocols than wget).

60. dd - used to convert and copy files.

61. fdisk - Modify the disk partition table.

62. parted – used to create and manipulate partition tables.

63. blkid - a command-line utility for finding and printing block device attributes.

64. mkfs - create a Linux file system.

65. fsck - an utility for determining the consistency of a file system.

66. nc - used for just about anything under the sun involving TCP or UDP.

67. umask - returns, or sets, the value of the system's file mode creation mask.

68. chmod – alters the access rights of file system objects.

69. chown – alter the owner and group of a file.

70. chroot - used to change the root directory.

71. useradd - create a new user or alter the default information for a new user.

72. userdel - used to delete a user account and all associated files.

73. usermod – used to edit or change any existing user account's properties.

74. vi is a text editor.

75. cat – displays the contents of a file.

76. tac – reverse output file contents.

77. more - show file contents one screen/page at a time.

78. less – identical to more, but with more features.

79. tail – used to show the last few lines of a text file or piped data.

80. head - used to show the first few lines of a text file or piped data.

81. dmesg – displays the kernel ring's message buffer.

82. journalctl - Tused to view systemd, kernel and journal logs.

83. kill - terminates a process.

84. killall - sends a kill signal to all instances of a specific process.

85. sleep – pauses program execution for a given amount of time.

86. wait – suspend script execution until all background jobs have been completed.

87. nohup - short for no hang up is a command in Linux systems that keep processes running even after exiting the shell or terminal.

88. screen – keep a remote server session open. (It also functions as a full-screen window manager.).

89. tmux is a terminal multiplexer.

90. passwd — Change the password.

What's Your Reaction?

like

dislike

love

funny

angry

sad

wow