Show Menu
Cheatography

KISSLinuxCommands Cheat Sheet (DRAFT) by

Cheat sheet for linux commands

This is a draft cheat sheet. It is a work in progress and is not finished yet.

HELP Commands

man
man provides short reference manuals
info
A newer form of online help is the in­fo ­command
help
help is a built-in command in the bash shell
tldr
community driven man pages

SYSTEM Commands

uname
details about the current machine and the operating system
uptime
how long the system has been running
hostname
Show or set the system's host name
reboot
Reboot the system
date
Sets or displays the system date
timeda­tectl
Control the system time and date
cal
Prints calendar inform­ation
w
Show who is logged on
whoami
Print the username

HARDWARE Commands

lscpu
Displays inform­ation about the CPU archit­ecture
lshw
Detailed inform­ation about hardware config­ura­tions
lsblk
Lists inform­ation about devices
df
Gives an overview of the filesystem disk space usage
du
estimate and summarize file and directory space usage
free
Display amount of free and used memory in the system
 

FILE Commands

ls
List directory contents
pwd
Print name of curren­t/w­orking directory
touch
Change a file access and modifi­cation times (atime, mtime)
cp
Copy files and direct­ories
mkdir
Creates a directory
mv
Move or rename files and direct­ories
rm
Remove files or direct­ories
chown
Change user and group ownership of files and direct­ories
chmod
Change the access permis­sions of a file or directory
wc
Count lines, words, and bytes
tr
Translate charac­ters: run replac­ements based on single characters and character sets
uniq
Output the unique lines from the given input or file
split
Split a file into pieces
head
Output the first part of files
tail
Display the last part of a file
more
Open a file for intera­ctive reading, allowing scrolling and search
less
Open a file for intera­ctive reading, allowing scrolling and search
cat
Print and concat­enate files
 

NETWORK Commands

ip
Show / manipulate routing, devices, policy routing and tunnels
ifconfig
Network Interface Config­urator
netstat
Displays networ­k-r­elated inform­ation such as open connec­tions, open socket ports, etc
whois
Comman­d-line client for the WHOIS (RFC 3912) protocol
dig
DNS lookup utility
nslookup
Query name server(s) for various domain records
host
Lookup Domain Name Server
hostname
Show or set the system's host name

PROCESS Commands

top
Display dynamic real-time inform­ation about running processes
ps
Inform­ation about running processes
kill
Sends a signal to a process, usually related to stopping the process