Cheat Sheet Library
Quick technical references for the commands and facts you look up constantly. Use your browser's print function (Ctrl/Cmd+P) to print any sheet.
Windows Command Prompt
16 entriesThe commands you reach for constantly at a Windows help desk.
| ipconfig /all | Full network configuration for every adapter |
| ipconfig /release + /renew | Drop and request a new DHCP lease |
| ipconfig /flushdns | Clear the local DNS resolver cache |
| ping <host> | Test basic reachability and latency |
| tracert <host> | Show the path packets take, hop by hop |
| nslookup <host> | Resolve a hostname to an IP via DNS |
| netstat -an | List active connections and listening ports |
| arp -a | Show the local ARP (IP-to-MAC) cache |
| route print | Show the local routing table |
| systeminfo | Full system and OS summary |
| gpupdate /force | Force an immediate Group Policy refresh |
| gpresult /r | Show which GPOs actually applied |
| sfc /scannow | Scan and repair protected system files |
| whoami | Show the current user context |
| tasklist | List running processes |
| taskkill /PID <id> /F | Force-terminate a process by ID |
Linux Command Line
15 entriesCore commands for administering and troubleshooting Linux systems.
| ip addr | Show network interfaces and IP addresses |
| ip route | Show the routing table |
| ping <host> | Test reachability and latency |
| traceroute <host> | Show the path to a destination, hop by hop |
| dig <host> | Detailed DNS lookup |
| ss -tulpn | List listening sockets and owning processes |
| journalctl -xe | Show recent, detailed system log entries |
| systemctl status <svc> | Check whether a service is running |
| systemctl restart <svc> | Restart a service |
| grep -R "text" . | Recursively search files for text |
| tcpdump -i eth0 | Capture live network traffic on an interface |
| df -h | Show disk space usage, human-readable |
| top / htop | Live view of process resource usage |
| chmod / chown | Change file permissions / ownership |
| tail -f /var/log/syslog | Follow a log file live as it updates |
PowerShell
12 entriesStructured, object-based commands for Windows administration.
| Get-NetIPConfiguration | Full network config as structured objects |
| Test-NetConnection <host> -Port 443 | Test reachability to a specific port |
| Resolve-DnsName <host> | DNS lookup, structured output |
| Clear-DnsClientCache | Flush the local DNS cache |
| Get-Process | List running processes with resource usage |
| Get-Service | List Windows services and their status |
| Restart-Service <name> | Restart a Windows service |
| Get-ADUser -Identity <user> | Look up an Active Directory user (RSAT) |
| Unlock-ADAccount -Identity <user> | Unlock a locked AD account |
| Get-WinEvent -LogName System -MaxEvents 20 | Read recent system event log entries |
| Get-ExecutionPolicy | Check the current script execution policy |
| Invoke-WebRequest <url> | Make an HTTP request from the command line |
Git
13 entriesThe everyday Git workflow, from clone to push.
| git clone <url> | Copy a remote repository locally |
| git status | Show changed, staged, and untracked files |
| git add . | Stage all changes for commit |
| git commit -m "message" | Save staged changes with a message |
| git push | Send local commits to the remote |
| git pull | Fetch and merge remote changes |
| git branch <name> | Create a new branch |
| git checkout -b <name> | Create and switch to a new branch |
| git merge <branch> | Merge a branch into the current one |
| git log --oneline | Compact commit history |
| git diff | Show unstaged changes |
| git stash | Temporarily shelve uncommitted changes |
| git reset --hard HEAD | Discard all local changes (careful!) |
Subnetting & CIDR
12 entriesThe subnet-mask-to-host-count table you always end up needing.
| /24 — 255.255.255.0 | 256 addresses, 254 usable hosts |
| /25 — 255.255.255.128 | 128 addresses, 126 usable hosts |
| /26 — 255.255.255.192 | 64 addresses, 62 usable hosts |
| /27 — 255.255.255.224 | 32 addresses, 30 usable hosts |
| /28 — 255.255.255.240 | 16 addresses, 14 usable hosts |
| /29 — 255.255.255.248 | 8 addresses, 6 usable hosts |
| /30 — 255.255.255.252 | 4 addresses, 2 usable hosts (point-to-point links) |
| 10.0.0.0/8 | Private range, ~16.7 million addresses |
| 172.16.0.0/12 | Private range, ~1 million addresses |
| 192.168.0.0/16 | Private range, ~65,000 addresses |
| 169.254.0.0/16 | Link-local / APIPA — no DHCP lease obtained |
| 127.0.0.0/8 | Loopback range |
Common Ports
15 entriesThe ports that come up constantly in networking and security work.
| 20 / 21 — FTP | File transfer, data / control channel |
| 22 — SSH | Secure remote shell and tunneling |
| 25 — SMTP | Mail transfer between servers |
| 53 — DNS | Domain name resolution |
| 67 / 68 — DHCP | Dynamic IP address assignment |
| 80 — HTTP | Unencrypted web traffic |
| 110 — POP3 | Mail retrieval (older) |
| 123 — NTP | Time synchronization |
| 143 — IMAP | Mail retrieval, multi-device sync |
| 389 — LDAP | Directory services (e.g. Active Directory) |
| 443 — HTTPS | Encrypted web traffic (TLS) |
| 445 — SMB | Windows file and printer sharing |
| 3306 — MySQL | MySQL/MariaDB database |
| 3389 — RDP | Windows Remote Desktop |
| 5432 — PostgreSQL | PostgreSQL database |