Differences
This shows you the differences between two versions of the page.
Next revision Both sides next revision | |||
linux_wiki:schedule_tasks_using_at_and_cron [2016/02/29 21:44] billdozor created |
linux_wiki:schedule_tasks_using_at_and_cron [2016/02/29 21:44] billdozor [cron] |
||
---|---|---|---|
Line 79: | Line 79: | ||
</ | </ | ||
* Executes / | * Executes / | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ==== Anacron ==== | ||
+ | |||
+ | Anacron runs all scripts in cron.* directories. This allows jobs to be run if the scheduled time was while a system was powered off. | ||
+ | |||
+ | Main config and contents: / | ||
+ | <code bash> | ||
+ | #period in days delay in minutes | ||
+ | 1 5 cron.daily nice run-parts / | ||
+ | 7 25 cron.weekly nice run-parts / | ||
+ | @monthly 45 cron.monthly nice run-parts / | ||
+ | </ | ||
+ | |||
+ | Run all anacron jobs(in / | ||
+ | <code bash> | ||
+ | anacron -f | ||
+ | </ | ||
+ | |||
+ | View timestamps for anacron jobs (cron.daily in this example) | ||
+ | <code bash> | ||
+ | cat / | ||
+ | </ | ||
+ | |||
+ | Run all jobs now, ignore delay specifications in / | ||
+ | <code bash> | ||
+ | anacron -n | ||
+ | </ | ||
---- | ---- | ||