@reboot Cron Expression
Fires once when the cron daemon starts — typically at system boot.
Expression
@rebootTry it in the tester →Field Breakdown
How It Works
`@reboot` is a Vixie-cron alias with no 5-field equivalent. It runs the job once after a system boot — modern implementations (cronie, Debian cron) write a flag file under `/run` the first time crond starts after boot, and skip `@reboot` on any subsequent restart of the daemon itself (config reload, package upgrade, etc.) until the next real boot.
Example Run Times
- On boot
- Not on a plain `systemctl restart cron` (already ran since boot)
- Not on a package-upgrade restart of crond (already ran since boot)
- Not on a cron config reload (already ran since boot)
Frequently Asked Questions
Is `@reboot` portable?
It's supported by Vixie cron, cronie, and most Linux distributions, but not by strict POSIX cron, BSD cron, or Quartz. For boot-time work on systemd systems, prefer a unit with `[Install] WantedBy=multi-user.target`.
Does `@reboot` fire if I just restart the cron service?
No, not on modern implementations. cronie and Debian cron write a flag file under `/run` (e.g. `/run/crond.reboot`) the first time the daemon starts after a boot, and skip `@reboot` jobs on later daemon restarts — only an actual system boot clears that flag and re-fires them. (Only the original 1987-era Vixie cron re-ran `@reboot` on every daemon start; that's not how cronie/Debian cron behave today.)