Use it to schedule jobs, or when a scheduled job did not run.
Timers
A systemd timer (.timer) starts a matching .service on a schedule (OnCalendar=) or after an interval (OnBootSec=, OnUnitActiveSec=). It replaces many cron jobs with logging and dependency support.
1. systemctl list-timers --all — next and last run.
2. Timer enabled and active? systemctl is-enabled <name>.timer.
3. systemd-analyze calendar '<OnCalendar>' — schedule as intended?
4. journalctl -u <name>.service — did the job run and succeed?
5. Run once by hand: systemctl start <name>.service.
timer active → schedule reached → matching service started → job runs → result in the journal
For systemd & Services → Timers, continue with the first unproven Topic check: Resolve the timer and its triggered unit, including any override/drop-in configuration. If that boundary is healthy, advance to the adjacent check: Capture next/last trigger, schedule expression, timezone/clock context, persistence and randomized delay. Preserve the same host/time/identity scope and rerun the original workload before accepting recovery.
Continue only after interpreting the current observation.Context & applicabilityCommon mistakes · platform/version boundaries
Operational reference
Fast context before you go deeper.
Verification & Troubleshooting
Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.
Use the operational verification above to establish the expected state.
Capture the concrete output, symptom, packet, log or counter before changing anything.
Step 1 Operational evidence path Verify boundary
timer definition → clock/monotonic schedule evaluation → timer trigger → associated unit job → process/service execution → output/side effect → workload acceptance
Healthy evidence: schedule interpretation, trigger timestamps and associated service execution all align, and the intended scheduled side effect is verified.
Step 2 Verification and output interpretation Verify boundary
Existing fast checks for this Topic. - Resolve the timer and its triggered unit, including any override/drop-in configuration.
- Capture next/last trigger, schedule expression, timezone/clock context, persistence and randomized delay.
- Correlate trigger timestamp with the associated service job and journal outcome.
- Verify the actual scheduled workload result, not only timer state.
Verification chain. timer definition → clock/monotonic schedule evaluation → timer trigger → associated unit job → process/service execution → output/side effect → workload acceptance
Step 3 Commands Verify boundary
systemctl list-timers
systemctl cat backup.timer
Step 4 Failure modes and next checks Narrow the fault
Suspicious evidence: timer shows active/waiting so operators assume the last or next workload execution is successful.
Step 5 Common mistakes Narrow the fault
- Timer without matching service.
Evidence · 1 on this Topic
Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.
Enable the .timer, not the .service. Persistent=true runs missed jobs after downtime. Test the schedule with systemd-analyze calendar '<expr>'. Output goes to the journal of the .service.
systemctl list-timers --all— timers with next and last runsystemctl status <unit>— state, main PID, recent log linessystemctl list-units --failed— failed unitsjournalctl -u <unit> -b— the unit's log since bootsystemctl cat <unit>— unit file plus drop-inssystemd-analyze verify <unit>— unit file errors
ReferenceWhat it is1 section · depth on demand
Core model
Inspect both the .timer unit and the unit it activates. Verify OnCalendar/monotonic expressions, timezone/clock assumptions, Persistent and randomized-delay behavior, next/last trigger times and whether the associated service job actually ran successfully. A timer can be active and waiting while the triggered job repeatedly fails.
ReferenceHow it works1 section · depth on demand
How it works
How it works: systemd resolves unit files/drop-ins, dependencies/order, conditions and environment, then forks/execs or activates the service and tracks its main process/readiness according to Type.
ReferenceImportant terms & boundaries5 sections · depth on demand
What this shows and what it does not
Timer state shows scheduling and trigger behavior within systemd, not successful execution or correctness of the triggered workload.
In depth
systemd timers: schedules, catch-up and spreading load
A timer unit starts another unit, normally a service with the same name, on a schedule. The systemd.timer(5) manual page defines two kinds of trigger:
- Monotonic timers count from an event.
OnBootSec=counts from boot,OnStartupSec=from when the manager started,OnActiveSec=from when the timer was activated, andOnUnitActiveSec=andOnUnitInactiveSec=from the last start or stop of the triggered unit. - Realtime timers use
OnCalendar=with calendar expressions.
Behaviour settings (manual)
| Setting | Default | Purpose |
|---|---|---|
Persistent= | false | Run a missed OnCalendar= job at the next boot |
AccuracySec= | 1 min | Window for coalescing wake-ups; 1us for precision |
RandomizedDelaySec= | 0 | Random delay to spread jobs across many machines |
Unit= | Same name as the timer | Which unit to start |
WakeSystem= | false | Resume from suspend to run the job |
Timers get an automatic Before=timers.target, and are enabled with WantedBy=timers.target.
Calendar expressions
| Expression | Meaning |
|---|---|
daily | Every day at 00:00 |
Mon..Fri 07:30 | Weekdays at 07:30 |
*-*-* 02:15:00 | Every day at 02:15 |
*:0/15 | Every 15 minutes |
Sun *-*-1..7 03:00 | First Sunday of the month |
host$ cat /etc/systemd/system/db-backup.timer
[Unit]
Description=Nightly database backup
[Timer]
OnCalendar=*-*-* 02:15:00
RandomizedDelaySec=20min
Persistent=true
[Install]
WantedBy=timers.target
host$ systemd-analyze calendar "*-*-* 02:15:00"
Original form: *-*-* 02:15:00
Normalized form: *-*-* 02:15:00
Next elapse: Sun 2026-11-29 02:15:00 CET
host$ sudo systemctl enable --now db-backup.timer
host$ systemctl list-timers db-backup.timer
host$ journalctl -u db-backup.service --since yesterday
Timers compared with cron
| systemd timer | cron | |
|---|---|---|
| Logs | Journal per unit | Mail or a log file |
| Missed runs | Persistent=true | Lost (unless anacron) |
| Overlap | A running service isn't started twice | Can start overlapping copies |
| Resource limits | All service settings available | None |
Enable the .timer unit, not the service. The service usually has no [Install] section and shows as static.
Documented example, not captured output.
How it works at runtime
Timers is part of systemd & Services → Timers. systemd timers schedule activation of units using monotonic or realtime calendar triggers, persistence and randomized delays; the timer firing and the triggered service succeeding are separate events.
Topic-specific state model. systemd timers schedule activation of units using monotonic or realtime calendar triggers, persistence and randomized delays; the timer firing and the triggered service succeeding are separate events.
Interpretation rule. - Timer active ≠ triggered service succeeded.
- Timer elapsed ≠ job produced the intended workload result.
- OnCalendar expression ≠ guaranteed wall-clock execution during downtime unless persistence semantics cover it.
- Next trigger time ≠ evidence system clock/timezone is correct for business intent.
Quick reference
systemd timers replace cron for many tasks, with logging, dependencies and missed-run handling.
# /etc/systemd/system/backup.service
[Service]
Type=oneshot
ExecStart=/usr/local/bin/backup.sh
# /etc/systemd/system/backup.timer
[Timer]
OnCalendar=*-*-* 02:30:00
RandomizedDelaySec=15m
Persistent=true
[Install]
WantedBy=timers.target
systemctl enable --now backup.timer
systemctl list-timers --all
systemd-analyze calendar 'Mon..Fri 07:00'
journalctl -u backup.service
Persistent=true runs missed jobs after downtime; OnBootSec=/OnUnitActiveSec= give monotonic intervals.
Limits and how it fails
Primary failure point. Timer state shows scheduling and trigger behavior within systemd, not successful execution or correctness of the triggered workload.
ReferenceConfiguration & state1 section · depth on demand
Configuration, persistence and lifecycle
Distribution/platform context. Timers owns systemd scheduling semantics. Scheduling branch may cover cron comparison; the triggered service owns its application work.
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Verification history & basis
When and against what this Topic was checked. Later text edits do not count as a new check.
Authoritative/upstream documentation reviewed for bounded claims in systemd & Services → Timers. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://systemd.io/ · confidence 94%Authoritative Linux project/vendor documentation reviewed for bounded reference claims: timer activation, calendar/monotonic scheduling and triggered-unit relationship. Documentation-based technical verification only; not lab or production-runtime proof. The schema vendor_doc method is used for authoritative project/vendor documentation; deployment applicability remains separate evidence.
Basis: https://man7.org/linux/man-pages/man5/systemd.timer.5.html · confidence 93%What changed and what may be affected
Recent technical edits are separated from ordinary page timestamps. Relationship impact is advisory: it identifies nearby canonical references to review, not automatic breakage.
Terms & aliases
Hover a linked term for a quick definition; click it to open its glossary entry. Aliases are other names that find this Topic in search.
Quick lookup tables
Timers operational reference
Topic-specific lookup boundaries, proof limits and next-step Evidence for Timers.
| Lookup boundary | Topic-specific reference | Operational use |
|---|---|---|
| Scope / effective state | systemd timers schedule activation of units using monotonic or realtime calendar triggers, persistence and randomized delays; the timer firing and the triggered service succeeding are separate events. | Establish exactly what this Topic owns before crossing into another subsystem. |
| Fast verification | Pin host/container + timestamp → identify exact process or unit → capture PID plus start identity and cgroup/unit → resolve effective unit fragment + drop-ins → inspect dependency/order transaction → record systemd job result → verify process/cgroup and active/sub state → prove application readiness → repeat the original workload test. | Use the shortest evidence path first; a fast check is a boundary test, not blanket proof. |
| Verification chain | timer definition → clock/monotonic schedule evaluation → timer trigger → associated unit job → process/service execution → output/side effect → workload acceptance | Trace requested/configured state through effective state to the observed workload result. |
| Failure boundary | Timer state proves scheduling and trigger behavior within systemd, not successful execution or correctness of the triggered workload. | Stop broad troubleshooting at the first boundary that is not supported by evidence. |
| Positive evidence | Correlated Linux process/systemd evidence can establish this proof path: timer definition → clock/monotonic schedule evaluation → timer trigger → associated unit job → process/service execution → output/side effect → workload acceptance | Use this observation only for the specific claim it actually supports. |
| Evidence limit | It does not independently prove behavior outside the captured process, manager, unit, dependency, runtime or application scope. Timer state proves scheduling and trigger behavior within systemd, not successful execution or correctness of the triggered workload. | Do not promote a local success signal into end-to-end or adjacent-dependency proof. |
| Next troubleshooting check | Continue from the first unproven boundary: reacquire stable process identity, inspect effective loaded unit configuration and dependency/job state, correlate process/cgroup plus journal evidence, then run the original readiness/workload test before changing additional settings. | Continue to the next unresolved boundary while preserving the original test condition. |
Timers · operational reference
Compact Linux state, persistence, verification and boundary reference for fast lookup.
| Reference boundary | Timers |
|---|---|
| Topic path | systemd & Services → Timers |
| Runtime state | systemd timers schedule activation of units using monotonic or realtime calendar triggers, persistence and randomized delays; the timer firing and the triggered service succeeding are separate events. |
| Fast checks | - Resolve the timer and its triggered unit, including any override/drop-in configuration. - Capture next/last trigger, schedule expression, timezone/clock context, persistence and randomized delay. - Correlate trigger timestamp with the associated service job and journal outcome. - Verify the actual scheduled workload result, not only timer state. |
| Verification chain | timer definition → clock/monotonic schedule evaluation → timer trigger → associated unit job → process/service execution → output/side effect → workload acceptance Boundary chain: local authoritative state → adjacent dependency → effective/programmed state → original workload/request → return/regression → explicit Evidence boundary. Boundary chain: local authoritative state → adjacent dependency → effective/programmed state → original workload/request → return path or regression → explicit Evidence boundary. |
| Failure boundary | Timer state proves scheduling and trigger behavior within systemd, not successful execution or correctness of the triggered workload. Boundary chain: unit config/drop-ins → dependency/order/condition → exec/process → readiness/active state → owned socket/file/device → dependent client/workload. |
| Persistence rule | Prove which configuration source owns the state, then prove that the running consumer loaded or generated the intended state. |