What are systemd unit types?
A unit is any resource systemd manages; the file extension names its type — .service (a daemon), .target (a group of units), .socket, .mount, .timer, etc.
* systemd models everything as a "unit" — the file extension names the type (.service, .target, .socket, .timer, .mount, .path). *
systemd doesn't only manage services — it models everything it touches as a "unit", and the suffix tells you what kind. This uniform model is what lets one tool (systemctl) start a service, mount a filesystem, or schedule a job.
| Type | Extension | Purpose |
|---|---|---|
| Service | .service |
A daemon or process |
| Target | .target |
A named group of units (replaces SysV runlevels) |
| Socket | .socket |
A socket for on-demand activation |
| Mount | .mount |
A filesystem mount point |
| Automount | .automount |
A mount that activates on first access |
| Timer | .timer |
A schedule (the systemd answer to cron) |
| Path | .path |
Watches a file/dir and triggers on change |
| Swap | .swap |
A swap area |
| Slice | .slice |
A cgroup for resource control |
| Scope | .scope |
A group of externally-started processes |
Targets deserve a closer look — they're how systemd reaches a "system state" by pulling in a bundle of units, much like the old runlevels:
multi-user.target— full system, no GUI (≈ runlevel 3)graphical.target— adds the graphical login (≈ runlevel 5)rescue.target— minimal single-user repair mode
Tip: day to day you'll mostly handle .service units; the others appear once you start scheduling (.timer) or controlling resources (.slice).