Hey,
Question: is it OK to have installed anacron and cron on the same machine?
After reading the doc, I'm still not quite sure to understand anacron.
Especially when I'm looking at the following files:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
# m h dom mon dow user command
17 * * * * root cd / && run-parts --report /etc/cron.hourly
25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily )
47 6 * * 7 root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.weekly )
52 6 1 * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.monthly )
#
# These replace cron's entries
1 5 cron.daily nice run-parts --report /etc/cron.daily
7 10 cron.weekly nice run-parts --report /etc/cron.weekly
@monthly 15 cron.monthly nice run-parts --report /etc/cron.monthly
Based on crontab file, I can see that the files in /etc/cron.daily/ will be executed everyday at 6:26am.
Based on anacrontab, will the same files (in /etc/cron.daily) be also executed at 1am?
Does Anacron, at 1am, can see that the last time the files in /etc/cron.daily were executed less than 24hours ago, so it will not run them?
Question: is it OK to have installed anacron and cron on the same machine?
After reading the doc, I'm still not quite sure to understand anacron.
Especially when I'm looking at the following files:
- crontab file:
Quote:
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
# m h dom mon dow user command
17 * * * * root cd / && run-parts --report /etc/cron.hourly
25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily )
47 6 * * 7 root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.weekly )
52 6 1 * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.monthly )
#
- anacrontab file:
Quote:
# These replace cron's entries
1 5 cron.daily nice run-parts --report /etc/cron.daily
7 10 cron.weekly nice run-parts --report /etc/cron.weekly
@monthly 15 cron.monthly nice run-parts --report /etc/cron.monthly
Based on crontab file, I can see that the files in /etc/cron.daily/ will be executed everyday at 6:26am.
Based on anacrontab, will the same files (in /etc/cron.daily) be also executed at 1am?
Does Anacron, at 1am, can see that the last time the files in /etc/cron.daily were executed less than 24hours ago, so it will not run them?
No comments:
Post a Comment