Hide Forgot
Description of problem: cron.weekly/ jobs were always run on Sunday. Now they run on any unspecific day, usually on Monday but even other weekdays. As for example /etc/cron.weekly/99-raid-check affects machine performance for a long time its load may creep into a workday. Version-Release number of selected component (if applicable): FAIL: cronie-1.4.7-1.fc14 + crontabs-1.11-1.20101115git.fc14 FAIL: RHEL-6.0 (and whatever Fedora it was derived from) PASS: RHEL-5.0 (and whatever Fedora it was derived from) How reproducible: Always. Steps to Reproduce: grep cron.weekly /var/log/cron* Actual results: F-14: Jun 20 = Monday Jun 27 = Monday Jul 4 = Monday ScientificLinux-6.0: Jun 17 = Friday Jun 24 = Friday Jul 1 = Friday Expected results: CentOS-5.5: Jun 26 = Sunday Jul 3 = Sunday Jul 10 = Sunday Additional info: CentOS-5.5: /etc/crontab: 22 4 * * 0 root run-parts /etc/cron.weekly man 5 crontab day of week 0-7 (0 or 7 is Sun, or use names) F-14: #period in days delay in minutes job-identifier command 7 25 cron.weekly ... /etc/cron.weekly
You can install cronie-noanacron and remove cronie-anacron package as a workaround.
As was posted in previous comment you can use old /etc/crontab setting from cronie-noanacron package. Or you can change these two lines in /etc/anacrontab: #RANDOM_DELAY=45 7 0 cron.weekly nice run-parts /etc/cron.weekly I guess randomization of jobs push weekly to the Monday. Or do they run on Monday because you switched off your computer for weekend?
My systems all run 24x7. They are only shortly rebooted once approx. a month. I do not know why but F16 runs cron.weekly now correctly at Sat-Sun midnight. cron-20120528:May 26 00:33:01 host2 anacron[5200]: Job `cron.weekly' started cron-20120528:May 26 09:15:51 host1 anacron[12864]: Job `cron.weekly' started cron-20120603:Jun 2 00:37:01 host2 anacron[6928]: Job `cron.weekly' started cron-20120603:Jun 2 09:01:39 host1 anacron[4019]: Job `cron.weekly' started cron-20120611:Jun 9 00:40:59 host2 anacron[23916]: Job `cron.weekly' started cron-20120611:Jun 9 08:21:24 host1 anacron[32471]: Job `cron.weekly' started cron-20120617:Jun 16 00:38:01 host2 anacron[11370]: Job `cron.weekly' started cron-20120617:Jun 16 08:22:40 host1 anacron[13504]: Job `cron.weekly' started Moreover the only problematic weekly script "raid-check" is no longer affected: * Fri Mar 25 2011 Doug Ledford <dledford> - 3.1.5-1 - Move the raid-check script from cron.weekly to /usr/sbin, add a crontab file to /etc/cron.d and mark it config(noreplace). This way users can select their own raid-check frequency and have it honored through upgrades. ==> /etc/cron.d/raid-check <== # Run system wide raid-check once a week on Sunday at 1am by default 0 1 * * Sun root /usr/sbin/raid-check So in fact I no longer care when cron.weekly/ is being run, either if it has been fixed or not.