Bug 196746 - run-crons should allow specification of fixed times for running jobs
Summary: run-crons should allow specification of fixed times for running jobs
Status: RESOLVED DUPLICATE of bug 114761
Alias: None
Product: SUSE LINUX 10.0
Classification: openSUSE
Component: Basesystem (show other bugs)
Version: unspecified
Hardware: Other Other
: P5 - None : Normal
Target Milestone: ---
Assignee: Klaus Singvogel
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-08-03 08:30 UTC by Alan Iwi
Modified: 2006-08-03 13:37 UTC (History)
0 users

See Also:
Found By: Other
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alan Iwi 2006-08-03 08:30:30 UTC
Here is an excerpt from /etc/crontab on a RedHat system:

01 * * * * root run-parts /etc/cron.hourly
02 4 * * * root run-parts /etc/cron.daily
22 4 * * 0 root run-parts /etc/cron.weekly
42 4 1 * * root run-parts /etc/cron.monthly

As you can see, these jobs will run at a fixed time of hour / day / week / month.

By contrast, the run-crons on SUSE potentially runs jobs every hour, and they actually run whenever there is a certain elapsed time since the job was last run.  Although this may be useful in certain circumstances (e.g. a machine which has a lot of down-time), I find it unhelpful when some of the cron.daily jobs run during office hours, particularly updatedb which does a disk-intensive "find".  It would be much better in this case to schedule these to happen at fixed times, in particular so that cron.daily scripts run during the night.  So personally I have copied the run-parts script and /etc/crontab entries from the RedHat system, and commented out run-crons from /etc/crontab.

I am not suggesting that you force this behaviour for everybody, but at least make it a configurable option please.

Many thanks.
Comment 1 Michael Gross 2006-08-03 13:13:04 UTC
You sure can setup cron that way yourself. What you propose is an Enhancement.
Klaus, please decide.
Comment 2 Klaus Singvogel 2006-08-03 13:37:07 UTC
There exists a mechanism to do so.

You can delete files (or change there modification time) in /var/spool/cron/lastrun/cron.daily at specific time to let cronjobs start later.
http://susewiki.org/index.php?title=Scheduling_daily_cron_jobs

*** This bug has been marked as a duplicate of bug 114761 ***