Scheduled Jobs and Timers

Work that happens on its own

Servers do a lot of work on a schedule with nobody watching: back up data overnight, clean up temporary files, rotate logs, send a report every morning. On a systemd machine these are timers. A timer is a unit (something.timer) that starts another unit — usually a service of the same name — when its schedule comes due.

systemctl list-timers shows the timers on a machine: when each one next runs, when it last ran, and the service it triggers. --all includes ones that aren't active:

systemctl list-timers --all --no-pager

In the terminal

student@vulntech:~$ systemctl list-timers --all --no-pager
NEXT               LEFT      LAST PASSED UNIT                ACTIVATES
Sun 2026-10-18 07… 7min left -    -      systemd-tmpfiles-c… systemd-tmpfiles-c…
Mon 2026-10-19 00… 16h left  -    -      dpkg-db-backup.tim… dpkg-db-backup.ser…
Mon 2026-10-19 06… 23h left  -    -      man-db.timer        man-db.service
-                  -         -    -      apt-daily-upgrade.…
-                  -         -    -      apt-daily.timer
-                  -         -    -      e2scrub_all.timer
-                  -         -    -      fstrim.timer

7 timers listed.

Think of it like this: A timer and its service are a pair. backup.timer holds the schedule (“every night at 2am”); backup.service holds the work (the command that does the backup). The timer's only job is to start the service on time.

Tip: systemd timers have replaced cron on most modern Linux systems. The idea is the same — run a job on a schedule — but timers are themselves units, so they're listed, logged and managed with the same systemctl and sudo journalctl you already know.

Remember: A systemd timer (name.timer) starts a service (name.service) on a schedule. systemctl list-timers --all lists the timers and when they run.

HOME LEARN COMMUNITY DASHBOARD
Practice terminal Starting…