What a systemd unit is, the common unit types, and how to start, stop, enable and inspect services with systemctl.
A systemd unit is a configuration object that systemd, the init system of most Linux distributions, manages: services, sockets, timers, mounts and more. Units are described by unit files such as /etc/systemd/system/<name>.service and controlled with the systemctl command.
.service runs a program, .socket starts a service when a connection arrives, .timer runs a unit on a schedule, .mount and .automount handle file systems, .target groups units into states such as multi-user.target.
Packages install units in /usr/lib/systemd/system (or /lib/systemd/system). Local changes belong in /etc/systemd/system, which takes precedence. 'systemctl edit <unit>' creates a drop-in override instead of changing the packaged file.
'systemctl status <unit>' shows state and the last log lines. 'start', 'stop' and 'restart' act now; 'enable' and 'disable' control starting at boot; 'enable --now' does both. 'systemctl --failed' lists failed units, and 'systemctl daemon-reload' rereads unit files after changes.
systemctl --failedsystemctl status <unit>journalctl -u <unit> -bsudo systemctl restart <unit>systemctl edit', not by editing files in /usr/lib/systemd/system: updates overwrite them.Last updated: 2026-10-08
How to read logs with journalctl, check how much space the journal uses and shrink it safely with --vacuum options.
How cron runs scheduled jobs, the five crontab time fields, where system cron files live and how systemd timers compare.
What logrotate does, how its configuration in /etc/logrotate.conf and /etc/logrotate.d works, and how to test a rule safely.