cron vs systemd Timers
Compare the two ways to schedule recurring jobs on Linux.
| Dimension | cron | systemd timers | What it means in practice |
|---|---|---|---|
| Definition | One line per job in crontab. | A .timer unit plus a .service unit. | Timers need two files but gain systemd features. |
| Logging | Output mailed or redirected manually. | Output goes to the journal automatically. | journalctl -u <service> shows each run. |
| Missed runs | Missed while powered off are skipped (anacron aside). | Persistent=true runs missed jobs at boot. | Useful for laptops and VMs that are not always on. |
| Dependencies and limits | None built in. | Can depend on other units and use resource limits. | Timers can wait for network-online.target. |
| Listing | crontab -l per user; /etc/cron.d. | systemctl list-timers. | list-timers shows last and next run times. |
| Verification | grep CRON /var/log/syslog (or journalctl -u cron) | systemctl status <name>.timer; journalctl -u <name>.service | Confirm the environment: cron has a minimal PATH. |