Stage 1 · Lesson 4 of 10
Services with systemd
is the program that starts and looks after services on most systems. A service is a program that runs in the background, such as a web server. You control services with systemctl: start, stop, restart, enable (start at boot) and status.
Each service is described by a small text file called a unit file. It says which command to run, which user to run it as and what to do if it crashes, for example Restart=on-failure. Writing your own unit file turns a script or app into something that survives crashes and reboots.
restart policies and Deployments do the same job later, at larger scale. When a service fails, systemctl status shows its last log lines and its .
Common trapstarting apps with nohup or inside a screen session, which works until the server reboots and nothing comes back.
A question to check yourself, an AI practice session and 1 cheat sheet entry come with the full roadmap. Unlock
Resources for this stage
Start with· follow one of these
- CourseFreeThe Missing Semester of Your CS Education
MIT · Beginner
Shell, scripting, data wrangling, SSH and Git in a dozen focused lectures
- BookFreeThe Linux Command Line
William Shotts · Beginner
Free book: permissions, processes, packages and longer shell scripts, chapter by chapter