Automation · Linux Automation
systemd
Cheat sheet · https://pcornel.dk/topic.php?topic=5655
Answer
systemd Automation manages Linux units, enablement, daemon configuration and service lifecycle while separating unit-file persistence, manager reload, active state and application readiness.
Remember
- Unit file written ≠ systemd manager loaded it.
- enabled ≠ active.
- active ≠ application ready.
- restart command success ≠ dependency or workload health.
First checks
systemctl is-active <svc>— statesystemctl is-enabled <svc>— boot enablementsystemd-analyze verify <unit>— unit file check
Verify in this order
unit file → daemon-reload → service state
Where it usually breaks
systemd state proves service-manager observations, not full application correctness or dependency health.
systemd automation proof-boundary map
| Boundary | Healthy evidence | Suspicious evidence |
|---|---|---|
| Scope / identity | Exact source revision, hosts and execution identity are explicit | Selector drift, stale inventory or wrong token changes scope/authority |
| Operation | Tool/provider action and per-host result are traceable | Partial failure, hidden error semantics or environment differences are lost |
| Platform state | Persistent and effective state are read back | Command/cmdlet success is mistaken for convergence |
| Workload proof | Original service/application acceptance passes | Automation summary substitutes for actual runtime behavior |
Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=5655