Learning path
Linux: from zero to fixing a server
From your first ls to a server that won't start, in a terminal in your browser.
5 stages · 29 steps
Stage 1
First steps in the shell
Move around, work with files, and find help, in a safe terminal in your browser.
- 2
Lesson
Create, copy, move and delete: mkdir, touch, cp, mv, rm
Practice creating, copying, moving and deleting files and folders on Linux with mkdir, touch, cp, mv and rm, in a safe terminal in your browser, with automatic checks.
- 3
Lesson
Read files: cat, head, tail and less
Learn to read files on Linux with cat, head, tail and less, check which system you're on, and read a protected log with sudo, on Ubuntu or RHEL, Rocky and AlmaLinux.
- 4
Lesson
Help yourself: help, man, Tab and history
Stop memorizing Linux commands: learn to find the answer with help and man, type less with Tab, reuse commands with history, and check who you are with id.
- 2
Stage 2
Text and logs
Search, filter and count lines: the everyday skill behind every investigation.
- 5
Lesson
Search logs with grep
Learn grep on a real log, in your browser: find errors, ignore case, count matches, exclude lines, search whole folders, and read the login log on Ubuntu or RHEL.
- 6
Lesson
Connect commands: pipes and redirects
Learn how Linux commands work together: pipes, saving output with > and >>, hiding errors with 2>/dev/null, and tee, practiced on a real log in your browser.
- 7
Lesson
Count and sort: wc, cut, sort and uniq
Find the busiest IP address in a web server log with wc, cut, sort and uniq, building one command step by step, in a real terminal in your browser, with automatic checks.
- 8
Lesson
Change text in files with sed
Learn sed on a real config file, in your browser: preview a replacement, change the file with -i, keep a backup, replace all matches, print and delete lines.
- 9
Lesson
Find files with find
Learn the find command in a real terminal in your browser: search by name, type and size, spot empty files, delete safely, and find config files on Ubuntu or RHEL.
- 10
- 5
Stage 3
Permissions and users
Who may read, write and run what, and how sudo fits in.
- 11
Lesson
What rwx means, and chmod
Learn what rwx means, why a script says Permission denied, and how to fix it with chmod, including numbers such as 600 and 755, in a real terminal in your browser.
- 12
Lesson
Owners, chown and sudo
Learn who owns a file on Linux, why you get Permission denied, how sudo helps, and how to hand files to the web server with chown, on Ubuntu or RHEL and Rocky.
- 13
Article
"Permission denied" when running a script: 5 causes and fixes
Fix "bash: ./script.sh: Permission denied" and "bad interpreter" on Linux: execute bits, noexec mounts, directory permissions, Windows line endings and shebangs.
- 14
Article
"user is not in the sudoers file": how to get sudo back, even without the root password
Fix "user is not in the sudoers file": add yourself to the sudo or wheel group with su, recover without a root password, use visudo safely and fix a broken sudoers file.
- 11
Stage 4
The system
Disks, processes, services and ports, and the errors that come with each.
- 15
Lesson
Disk space: df and du
Learn to check disk space on Linux with df, find what uses it with du, sort the results and free some space, in a real terminal in your browser, with automatic checks.
- 16
Lesson
Processes: ps and kill
Learn to see what's running on Linux with ps, find a process with grep, stop it with kill, and know why services should be stopped with systemctl, in your browser.
- 17
Lesson
Services: systemctl and journalctl
Learn to check, stop and start services with systemctl, read their logs with journalctl, and see which names differ between Ubuntu and RHEL, Rocky and AlmaLinux.
- 18
Lesson
Ports: ss, lsof and curl
Learn to see what's listening on a Linux server with ss and lsof, test it with curl, and solve a port conflict between two web servers, on Ubuntu or RHEL.
- 19
Cheat sheet
systemctl and journalctl Cheat Sheet
Manage Linux services and read their logs: start, stop, enable, status, failed units, overrides, timers, and filtering journalctl by unit, time and priority
- 20
Article
"Job for nginx.service failed because the control process exited with error code": how to find the cause
Fix "Job for X.service failed because the control process exited with error code": read systemctl status and journalctl, test the config, and fix the usual causes.
- 21
Article
No space left on device: find what is filling your Linux disk
Fix "No space left on device" on Linux: find the biggest directories and files, free space safely, and handle the cases where df says there is space.
- 22
Article
"Address already in use": find who is using port 80 (or any port)
Fix "bind() failed (98: Address already in use)": find the process holding the port with ss or lsof, then stop it, move it, or change your port.
- 23
Article
Linux process "Killed" with no error: find the OOM killer and stop it happening again
A process that just prints "Killed" (exit code 137) was usually stopped by the Linux OOM killer. Find it in the kernel log, see what used the memory, and fix it.
- 24
Article
"Too many open files" on Linux: raise the right limit, or find the leak
Fix "Too many open files" (EMFILE): check a process's real limit in /proc, raise LimitNOFILE for systemd services, and tell a low limit from a file descriptor leak.
- 15
Stage 5
Real incidents
Put it together on broken servers, then keep the checklist for the next one.
- 25
Lesson
Incident: the disk is filling up
A real incident to solve in your browser: a server is running out of disk. Find what's using the space with df, du and find, then free it safely with truncate.
- 26
Lesson
Incident: Nginx won't start
A real incident to solve in your browser: after a config change Nginx won't start. Read the error, find the line with nginx -t, fix it and start the service again.
- 27
Lesson
Incident: the site gives a 502
A real incident to solve in your browser: the API answers 502 Bad Gateway. Trace it from Nginx's error log to a crashed backend. On RHEL, SELinux adds one more step.
- 28
Guide
Disk full or server out of memory? Find the cause, step by step
No space left, a read-only disk, killed processes, or a limit reached.
- 29
Cheat sheet
Linux Troubleshooting Cheat Sheet
The commands to find out what is wrong on a Linux server: disk, memory, services, logs, ports, permissions, SSH and SELinux, on one printable page.
- 25
Your progress is saved in this browser only, never sent anywhere. Clearing the browser data clears it too.