- 论坛徽章:
- 2
|
stackExchange上的答案,如果安装了anacron 这个包,那么在/etc/cron.d/ 目录下会有相应的文件(我只有一个0hourly 文件,并没有0daily 之类的*_*)
其中规定了定时任务的执行时间:
Approximately 7:35am, but the exact timing will depend on anacron.
By default cron delegates the running of /etc/cron.daily jobs to anacron. /etc/crontab contains the line:
25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily )
but this defines the behaviour if anacron is not installed
With anacron installed, the running of cron.daily jobs is controlled by the entry in /etc/anacrontab:
1 5 cron.daily nice run-parts --report /etc/cron.daily
which says run these jobs once per day, with a delay of 5 minutes.
anacron itself is run by cron, as specified in the file /etc/cron.d/anacron, which runs anacron at 7:30am. |
|