You've learned for 25 minutes. A short break helps your brain.
Sprint done! Great focus. Stretch for a minute?
Linux & Networking commands
One page per command. What it does, when to use it, how risky it is.
Move around and read files
pwdPrints the path of the room (folder) you stand in.Risk: SafecdWalks you into another folder.Risk: SafelsLists what is in a folder.Risk: SafecatPrints a whole file at once.Risk: SafelessShows a long file one screen at a time. q quits.Risk: SafeheadShows the first lines of a file (10 unless you say -n).Risk: SafetailShows the last lines of a file: the newest ones in a log.Risk: SafemkdirMakes a new folder.Risk: SafecpCopies a file. The first one stays. It replaces a file with the same name without asking.Risk: CarefulmvMoves or renames a file or folder. It replaces a file with the same name without asking.Risk: CarefulrmDeletes files for good. There is no bin and no undo.Risk: Can lose worktouchMakes an empty file (or updates a file's time).Risk: Safe
Find and search
findSearches a folder and every folder inside it for matching names.Risk: SafegrepPrints only the lines that contain a word.Risk: SafewcCounts lines (-l), words or bytes.Risk: SafesortPuts lines in order: A to Z, or by number with -n.Risk: SafeuniqJoins repeated lines that sit together. -c counts them.Risk: SafecutKeeps only some columns of each line.Risk: SafesedChanges text on its way through. With -i it edits the file itself.Risk: Careful
Users and permissions
idShows a user's number and every group (team) they belong to.Risk: SafesudoRuns one command as root, the user with every key. The server writes it down.Risk: Carefulsudo useraddAdds a new user to the server.Risk: Carefulsudo usermodChanges a user, for example adds them to a group.Risk: CarefulchmodChanges the keys on a file: who may read, write or run it.Risk: Carefulsudo chownHands a file or folder to another owner (and group). Needs root.Risk: Careful
Processes, services and logs
psLists processes: programs at work, with their PID.Risk: SafetopA live list of processes, busiest first. q quits.Risk: SafepgrepPrints the PIDs of processes that match a name.Risk: SafekillSends a signal to a process: TERM (please stop) by default, KILL with -9.Risk: CarefuljobsLists the programs this terminal started in the background.Risk: SafeexportPins a variable on the wall, so programs you start can read it.Risk: SafewhichShows which file runs when you type a command name.Risk: Safesudo systemctlTalks to systemd, the shift manager: start, stop and check services.Risk: Carefulsudo journalctlReads the journal, systemd's diary of what services said.Risk: Safe
Packages
sudo aptFinds, installs and removes programs from Debian's own store.Risk: Careful
Network checks
ipShows this machine's addresses and the way out (its routes).Risk: SafessLists the ports that programs listen on.Risk: Safegetent hostsTurns a name into a number the way programs do: /etc/hosts first, then DNS.Risk: SafedigAsks DNS, the phone book, for a name. It skips /etc/hosts.Risk: SafecurlSpeaks HTTP with a web counter and prints its reply.Risk: Safeopenssl s_clientOpens a sealed line like a browser and shows the server's certificate.Risk: Safesudo ufwDebian's easy firewall: the guard's list of who may come in.Risk: CarefulpingSays hello to a machine and times the echo.Risk: SafetracerouteLists every exchange (hop) on the road to a machine.Risk: Safe
Remote servers and disks
sshOpens a sealed line to another machine, so you can type there.Risk: Safessh-keygenMakes a key pair: a padlock (.pub) and its one key.Risk: Safessh-copy-idHangs your padlock on a server: adds your public key to its authorized_keys.Risk: SafescpCopies files over SSH. It overwrites a file with the same name there.Risk: CarefulrsyncMakes a folder there match a folder here, sending only the changes.Risk: CarefuldfShows how full each disk is.Risk: SafeduShows how much space folders and files take.Risk: Safe
Scripts and schedules
crontabInstalls or shows your roster of scheduled jobs.Risk: Carefulsystemctl list-timersShows systemd timers: when each runs next and what it starts.Risk: SafesetStrict mode: a script stops at the first failure, unknown jar or broken pipe.Risk: Safe