Skip to content

Linux for Developers

Glossary

148 terms from Linux for Developers, in plain words, each with the chapter that teaches it.

#

$? (last exit code)
A shell variable holding the exit code of the last command. `echo $?` prints 0 if it worked and another number if it failed.
& (background job)
Putting `&` at the end of a command runs it in the background, so the shell gives you the prompt back at once instead of waiting.
&& and ||
`&&` runs the next command only if the first succeeded, and `||` runs it only if the first failed. For example, `systemctl is-active --quiet shop && echo "shop is up"`.
/dev/null
A special file that throws away anything written to it. `2>/dev/null` hides error messages, and `-o /dev/null` discards a curl response body.
/etc/hosts
A text file that maps names such as `localhost` to addresses. Linux checks it before asking DNS.
/etc/passwd
The file where each user is one line, with name, IDs, home folder and login shell. Groups live in `/etc/group`, and password hashes are in `/etc/shadow`, which only root can read.
/etc/sudoers
The file that says who may use sudo. On Ubuntu one line lets members of the `sudo` group run any command as any user.
2>&1 (redirect errors)
Sends error messages (stream 2) to the same place as normal output (stream 1). In cron jobs, `>> log 2>&1` puts both in the log file.

A

adduser
The command that creates a user with a matching group and home folder. With `--system --group` it creates a service account such as `kettle`. `deluser` removes a user.
adm
The Ubuntu group whose members may read system logs without sudo. Add a user to it (then they log in again) to let them read logs.
apt
Ubuntu and Debian's package manager. `apt update` refreshes the package list, `apt upgrade` installs newer versions, and `apt install`, `remove`, `purge` and `autoremove` add or take away software.
authorized_keys
The file on a server that holds the public keys allowed to log in to that account. sshd ignores it if its permissions are too open (use 700 on `~/.ssh` and 600 on the file).

B

bash
The usual Linux shell, the program that reads the commands you type and runs them. Scripts name it on their shebang line, `#!/bin/bash`.
bg
`bg` lets a paused job carry on in the background, and `fg` brings a job back to the foreground. Both usually follow Ctrl+Z.
body (HTTP)
The content of a web reply, such as the product list as JSON. It comes after the status code and headers.
broken link
A symbolic link whose target no longer exists. Reading it gives `No such file or directory`.

C

certbot
A tool that gets free HTTPS certificates from Let's Encrypt and sets them up in a web server such as nginx. It lets a site like Kettle & Crane's shop serve pages over encrypted HTTPS connections.
chgrp
A shortcut that changes only a file's group, such as `chgrp shop file`.
chmod
Changes a file's permissions, by letters (`u+x`) or by numbers (`644`, `755`). `-R` applies it to a whole folder. Never use `chmod 777` (everyone may do everything) to fix a permission problem.
chown
Changes a file's owner and group, written `user:group`. It needs sudo, as when Sam gives `/srv/shop` to `kettle:shop`.
client
The program that asks for something from a server. The `ssh` command on your laptop is the SSH client.
command substitution
Writing `$(command)` runs the command and puts its output into the line, for example `today=$(date +%F)`.
cron
The service that runs commands on a schedule. Each user has a crontab, a list of jobs edited with `crontab -e`, listed with `-l` and removed with `-r`.
cron time fields
The five fields at the start of a crontab line: minute, hour, day of month, month and day of week. `*` means every, `*/5` means every five, and `1-5` is a range.
curl
A command that fetches a web address and prints the reply. Options include `-i` (show headers), `-s` (silent), `-H` (add a header), `-o` (save the body) and `-w` (print the status code).

D

daemon
Another word for a service: a program that runs in the background all the time.
daemon-reload
Tells systemd to read unit files again. Run it after you add or change one.
date
Prints the current date and time. `date +%F` prints the date as year-month-day, which backup.sh uses in file names.
default gateway
The router that all traffic to other networks goes through. `ip route` shows it.
dependency
Another package that a package needs in order to work. apt installs them for you.
df
Shows how much disk space is used and free. `df -h /` shows the disk holding `/`, and a `Use%` near 100% means trouble.
dig
A tool that asks DNS directly for a name's address. `dig +short archive.ubuntu.com` prints only the answers.
distribution
Linux packaged with an installer, tools and software. Ubuntu, Debian, Fedora and Red Hat Enterprise Linux are distributions.
dnf
The package managers of Fedora, Red Hat and Rocky (`dnf`) and of Alpine (`apk`). They do the same job as apt on Ubuntu.
DNS (Domain Name System)
The system that turns names like archive.ubuntu.com into IP addresses, like a phone book.
dpkg
The low-level tool under apt that records every file each package installed. `dpkg -L` lists a package's files and `dpkg -S` finds which package owns a file.
du
Adds up how much space files and folders use. `du -sh /var/*` gives one readable total per folder.

E

enable and disable (systemd)
`enable` makes a service start at every boot and `disable` stops that; neither changes whether it is running now. `enable --now` enables and starts it in one go.
env
`env` lists all environment variables, `printenv NAME` prints one, and `export` makes a shell variable visible to the programs you start.
environment variable
A named setting passed from a process to the processes it starts, such as `HOME` or `SHOP_PORT`. A child gets a copy of its parent's exported variables.
EnvironmentFile
A systemd setting that loads variables from a file into a service. Kettle & Crane keeps the token in `/etc/shop/shop.env`, readable only by root.
exit code
The number a command ends with: 0 means success and anything else means failure. The shell keeps the last one in `$?`.

F

File tree (/, /etc, /var/log, /srv, /usr/bin)
Linux keeps every file in one tree starting at `/`, with no drive letters. Settings live in `/etc`, logs in `/var/log`, served data in `/srv` and programs in `/usr/bin`.
firewall
Rules that decide which network connections are allowed. The safe approach is to block everything and open only the ports you serve.
flush=True
A Python `print` option that shows the line straight away instead of holding it back. Without it, a service's log lines may not appear.
for loop
A shell loop that runs the same commands once for each word in a list, such as each file matched by a wildcard.
foreground
How a command normally runs: the shell waits for it to finish before giving you the prompt back.
free
Shows memory use. Read the `available` column for memory programs can still use.
function (shell)
A name given to a few shell lines you use more than once. Inside it, `$1` is the function's own first argument, as in pages.sh's `check`.

G

gid and uid
The numbers behind a user name (uid) and a group name (gid). Root's uid is 0.
grep -q and -E
`grep -E` allows patterns with `|` for "this or that". `grep -q` stays quiet and answers only through its exit code (0 if found, 1 if not).
group
A named set of users who share access to files. `groupadd` makes one, `groups` lists a user's groups, and `usermod -aG group user` adds someone (never leave out `-a`).

H

hash
A scrambled form of a password that can check a typed password but can't be turned back into it. `/etc/shadow` stores them.
header
A `Name: value` line sent with a web request or reply. The shop's `/orders` path needs an `X-Api-Token` header.
Host addresses (127.0.0.1, 0.0.0.0)
`127.0.0.1` (named `localhost`) always means "this machine", so a service listening only there can't be reached from outside. `0.0.0.0` means "every address this machine has", so anyone who can reach the server can reach that service.
host key fingerprint
A short code identifying a server's SSH identity. Check it the first time you connect; SSH saves it in `~/.ssh/known_hosts` and warns loudly if it changes.
hostname
The name of a machine, shown in your prompt and printed by the `hostname` command.
HTTP
The protocol web pages and APIs use, normally on port 80 (HTTPS, the secure form, on 443). A client sends a request such as `GET /products` and gets back a status code, headers and a body.

I

id
`id` shows your user ID and groups, `id -u` prints just the user ID (0 for root), and `whoami` prints your user name.
if statement
A shell decision: `if COMMAND; then ... else ... fi`. `[ ... ]` is a command that tests files, text or numbers and answers with its exit code.
interface
A network connection of a machine, such as `lo` (loopback) or `ens3`. `ip -br addr` lists them with their addresses.
IP address
A machine's number on a network, like `203.0.113.10`: four numbers from 0 to 255. `ip -br addr` shows yours.
IPv6
The newer address format, written with colons. Most servers have both IPv4 and IPv6 addresses, and ufw adds rules for both.

J

jobs
Lists your shell's background jobs, each with a job number in brackets. `kill %1` and `fg %1` refer to job 1.
journal
systemd's central log, where everything a service prints is collected along with systemd's own notes. It is read with `journalctl`.
journalctl
The reader for the journal. `-u` picks a unit, `-n` the number of lines, `-f` follows live, `--since` filters by time, `-b` limits to this boot and `-p err` to errors.
jq
A command that formats JSON and picks out parts of it. `.[0]` is the first item and `.[].name` is the name of every item.
JSON
A text format for data with lists `[...]` and objects `{...}`. The shop's `/products` answer is JSON.

K

kernel
The core of the operating system, which talks to the hardware and runs everything else. Strictly, "Linux" is the kernel.
key pair
A private key that never leaves your laptop plus a public key you put on servers you want to log in to. Sam's login uses this instead of a password.
kill
Sends a signal to a process. `kill PID` sends TERM (a polite stop), `kill -9` sends KILL (last resort), and `pkill NAME` signals by name.

L

Linux
An operating system kernel and the systems built on it. Most web servers and cloud services run on it.
ln -s
Makes a symbolic link: `ln -s TARGET LINKNAME`.
load average
Three numbers showing how many programs waited for the processor, averaged over 1, 5 and 15 minutes. If it stays above the number of cores, the server is overloaded.
log
Lines of text a program writes about what it's doing, each with a time. Logs are the first place to look when something goes wrong.
login shell
The program that runs when a user logs in. Service accounts like `kettle` use `/usr/sbin/nologin`, so nobody can log in as them.
logrotate
A daily job that renames, compresses and deletes old log files so they don't fill the disk. nginx's logs are kept for two weeks.
loopback
The pretend network inside a machine (`lo`), where `127.0.0.1` lives.
LTS (long-term support)
An Ubuntu release kept updated with security fixes for at least five years. Pick an LTS for any server you care about.

M

man
The built-in manual. `man cmd` shows the manual page for a command.
mode
A file's permissions, shown as `-rw-r--r--` or `644`. Three sets (owner, group, others) each allow read, write and execute.
Multipass
A free tool from Canonical that runs an Ubuntu server as a virtual machine on your laptop. You can delete it and start again in minutes.

N

nano
A simple terminal text editor. Ctrl+O saves and Ctrl+X exits.
nginx
A common web server. Kettle & Crane puts it in front of the shop app, and `nginx -t` checks its settings before a restart.
nginx site files (sites-available, sites-enabled)
nginx keeps one settings file per site in `/etc/nginx/sites-available/`. A link to it in `/etc/nginx/sites-enabled/` switches the site on, and removing the link switches it off.
nohup
Runs a command that ignores the hang-up signal, so it survives logout, and writes its output to `nohup.out`. Fine for a quick job, but real apps belong in systemd.
nproc
Prints the number of processor cores. Compare it with the load average.

O

openssl rand
A command that makes random data. `openssl rand -hex 16` prints 32 random characters, good for a token.
owner
The user a file belongs to. Together with the group and others, it decides which permission set applies to you.

P

package
Software bundled for installing, with a list of its dependencies. The package manager (apt on Ubuntu) installs and updates it.
parent process
The process that started another one. A child gets a copy of its parent's environment but can't change the parent's variables.
passphrase
A password that protects your private SSH key if your laptop is stolen. The SSH agent, a helper on most desktops, remembers it after the first use so you aren't asked every time.
passwd
Changes a password. `sudo passwd -l` locks an account (no logins, files kept) and `-u` unlocks it.
PATH
An environment variable listing the folders the shell searches for commands. That's why you type `./check.sh` for a script in the current folder.
Permission denied
The error you will see most on a server. It means the file's mode doesn't allow what you tried, as the user you are; check with `ls -l`.
pgrep
Finds processes by name and prints their PIDs. `-a` adds the full command line and `-f` matches the whole command line.
pid (process ID)
The number of a running process. PID 1 is systemd.
ping
Sends small test messages to a machine and times the replies. `ping -c 2` sends two, and some networks block it.
pipefail
A line placed after the shebang that makes a script stop on the first failing command (`-e`), on unset variables (`-u`) and on a failure in any part of a pipeline (`-o pipefail`).
port
A number that picks one service at an address, such as 22 for SSH, 80 for web pages and 443 for HTTPS. The shop app uses 8000.
process
A program while it runs. Each process has a PID, an owner and a parent.
proxy_pass
The nginx setting that forwards requests to another address. In the shop's nginx file, `location /api/` passes requests to the app on `127.0.0.1:8000`.
ps
Lists processes. `ps -eo pid,user,comm` shows every process with columns you choose, and `ps -u NAME` shows one user's.

R

repository
A server run by a distribution that holds signed packages. apt downloads software from it.
restart and reload
`restart` stops and starts a service, which you do after changing its settings or code. `reload` asks it to reread its settings without stopping, if it supports that.
Restart=on-failure
A unit file setting that makes systemd start a service again if it crashes or is killed, but not when you stop it on purpose. After five quick failures systemd gives up.
reverse proxy
A server, like nginx, that passes requests on to an app behind it. The public talks to nginx, and nginx talks to the shop app.
root
The administrator account, user ID 0, which can do anything. You work as yourself and borrow its power with sudo.
rsync
A copy tool that sends only what changed, so a second run is almost instant. A trailing `/` on the source copies the folder's contents.

S

scp
"Secure copy": copies a file to or from a server over SSH, using `name:path` for the server side.
Script arguments ($1, $#, "$@")
Inside a script, `$1`, `$2` are its arguments, `$#` is how many there are, `"$@"` is all of them (each kept whole, even with spaces) and `$0` is the script's own name.
server
A computer that runs programs for other computers, such as serving web pages. It usually has no screen and is controlled through a terminal.
service
A program that runs in the background all the time, waiting for work, such as nginx or the shop API. systemd starts and supervises services.
shebang
The first line of a script, such as `#!/bin/bash`, naming the program that runs it. It must be the very first line.
signal
A short message the system sends to a process. TERM asks it to finish and stop, KILL ends it at once, INT is sent by Ctrl+C and HUP by closing the terminal.
sleep
A command that waits a given number of seconds and then exits. It is handy for practicing with foreground and background jobs, and for giving a service a moment to start before checking on it.
snap
Ubuntu's second package format, which bundles an app with everything it needs and is installed with `snap install`.
ss
Shows network connections. `sudo ss -tlnp` lists which process listens on which TCP port.
SSH (secure shell)
An encrypted way to get a shell on another machine. The `ssh` client on your laptop connects to `sshd` on the server, on port 22.
ssh config
A file on your laptop that gives a server a short name, so `ssh shop` replaces `ssh sam@203.0.113.10`.
ssh-copy-id
Logs in with your password one last time and adds your public key to the server's `authorized_keys`.
ssh-keygen
Makes an SSH key pair; `ssh-keygen -t ed25519` picks ED25519, the modern key type. `ssh-keygen -R` removes an old entry from known_hosts.
sshd_config
The SSH server's settings. Sam adds `PasswordAuthentication no` and `PermitRootLogin no` in `/etc/ssh/sshd_config.d/`, then checks them with `sshd -t`.
stat
Shows details about a file. `stat -c '%a %A %n'` prints the mode as a number, as letters and the name.
status code
The number in a web reply: 200 OK, 301/302 moved (see the `Location` header), 401/403 not logged in or not allowed, 404 not found, 500 the app crashed, 502 bad gateway (nginx couldn't reach the app).
sudo
Runs one command as root after checking your own password. `sudo -u kettle CMD` runs as another user and `sudo -i` opens a root shell.
symbolic link
A small file that points to another path, like a shortcut. `menu.csv` pointing at `menu-2026-10.csv` marks the current menu.
system user
An account for a program rather than a person, such as `kettle`. It has no password and no login, so a bug or break-in can only touch the app's own files.
systemctl
The command that controls systemd. `status` checks health, `start` and `stop` act now, and `enable`/`disable` decide what starts at boot.
systemd
The first process (PID 1), which starts and supervises services from unit files.

T

tar
Packs a folder into one archive file (`-c`), compresses it (`-z`), names it (`-f`) and unpacks it (`-x`). backup.sh uses it for nightly backups.
target
A group of systemd units started together. `multi-user.target` means "the system is up and ready", and `WantedBy=` hooks a service into it.
TCP
The kind of network connection that web traffic and SSH use. `ss -t` shows TCP connections.
timer
A systemd unit that starts a service on a schedule. It is an alternative to cron, and logrotate runs from one.
tmux
A tool that keeps a terminal session alive on the server, so a long job survives a dropped SSH connection.
token
A secret password for an API. Kettle & Crane's `/orders` path answers only requests carrying the token, which is kept outside the code.
top
A live view of the busiest processes. `q` quits and `M` sorts by memory.
traceback
Python's report of where a program failed, such as the `FileNotFoundError` in the journal when products.json was missing.

U

Ubuntu
A popular Linux distribution, and the most common choice for servers. It has a long-term support (LTS) release every two years, and each LTS gets security fixes for at least five years.
ufw
Ubuntu's simple firewall tool. Allow SSH first with `ufw allow OpenSSH`, then web traffic, then `ufw enable`.
unattended-upgrades
An Ubuntu package that installs security updates automatically each day.
unit file
The text file that describes something systemd manages. Your own go in `/etc/systemd/system/`, with `[Unit]`, `[Service]` and `[Install]` sections, as in `shop.service`.
uptime
Shows how long the machine has been running, plus users and the load average. `-p` gives a readable form.
usermod
Changes a user. `usermod -aG GROUP USER` appends a group; leaving out `-a` replaces all the user's groups and can remove them from `sudo`.
UTC (Coordinated Universal Time)
The time zone most servers use so that logs from machines around the world line up. Portland is 7 hours behind in summer and 8 in winter.

V

virtual machine (VM)
A complete computer simulated inside another one. Multipass runs your practice server as one.

W

wildcard
A pattern like `/etc/*.conf` that the shell expands to all matching file names.
WSL
A Windows feature that runs Ubuntu inside Windows, installed with `wsl --install`. It is another way to practice.