SYSTEMD-CRONTAB-GENERATOR(8)
π SYSTEMD-CRONTAB-GENERATOR(8) β System Manager's Manual
okay bestie, sit down, hydrate, and let me tell you about systemd-crontab-generator π it lives in section 8 of the System Manager's Manual and it is literally the translator of the cron world.
β¨ NAME β¨
systemd-crontab-generator β translate cron schedules in systemd Units
πΈ SYNOPSIS πΈ
/usr/lib/systemd/system-generators/systemd-crontab-generator output-dir
π¦ DESCRIPTION π¦
So systemd-crontab-generator is a systemd.generator(7), and what it does β no cap β is translate the classic cron "FILES" into native systemd.timer(5)/systemd.service(5) pairs. iconic behaviour, honestly π
It runs automatically, all on its own, like the independent main character it is:
- during early boot,
- a second time by
cron-after-var.serviceif/varis a separate mount-point, so it can process user crontabs in/var/spool/cron/crontabs, - after each update to
/etc/crontabβ and/etc/anacrontabβ , and - when packages add files under
/etc/cron.dβ
(β : monitored by cron-update.path β that's the little watchful angel keeping an eye on things π§)
π FILES π
/etc/crontabβ the Administrator's system crontab, seecrontab(5)./etc/cron.dβ System crontabs managed by packages live here./etc/anacrontabβanacrontab(5)/var/spool/cron/crontabsβ Users' crontabs live here./run/systemd/generatorβ Automatically generated units go here./run/crond.rebootβ If this file exists,@rebootjobs aren't re-generated. Managed automatically./var/lib/systemd/timersβsystemd.timer(5)s with thePersistentflag set store their timestamps here.
π₯ DIAGNOSTICS π₯
systemctl list-timers shows an overview of current timers and when they'll elapse. lowkey the best way to vibe check your timers π
If you see something to the effect of
/usr/lib/systemd/system-generators/systemd-crontab-generator
failed with error code 1.
in the journal, you can run
/usr/lib/systemd/system-generators/systemd-crontab-generator /tmp/test
for more verbose output. it's giving detective work, and we love that for you π΅οΈπ
bestie the journal message means something went sideways β don't panic, just run the thing manually with /tmp/test as the argument and it'll spill all the tea.
π SEE ALSO π
crontab(5), systemd.timer(5), systemd.unit(5), systemd.cron(7)
and that's the whole page, periodt π«Ά this was systemd-cron version 2.8.2-1, dated 2023-08-13 β go forth and schedule responsibly, bestie πβ¨
π¦ where this page comes from
- ubuntu stonking: systemd-cron 2.8.2-1 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms