Randall R Schulz wrote:
On Tuesday 01 August 2006 16:42, Joachim Schrod wrote:
Dave Cotton wrote:
...
# At which time cron.daily should start. Default is 15 minutes after booting # the system. Due the cron script runs only every 15 minutes, it will only # run on xx:00, xx:15, xx:30, xx:45, not at the accurate time you set. DAILY_TIME="04:00"
AFAIR, the OP asked for 10.0 -- this sysconfig variable is new in 10.1.
puma:~ $ cat /etc/SuSE-release SUSE LINUX 10.0 (i586) VERSION = 10.0 puma:~ $ grep DAILY /etc/sysconfig/cron puma:~ $ grep DAILY /usr/lib/cron/run-crons puma:~ $
It may be newly documented in 10.1, but I tried in my 10.0 system, where there was no existing value in /etc/sysconfig/cron, and found that it _did_ control the execution time of the daily tasks.
Are you sure? The respective lines from /usr/lib/cron/run-crons are: test -e $SPOOL/$BASE && { case $BASE in cron.hourly) TIME="-cmin +60 -or -cmin 60" ;; cron.daily) TIME="-cmin +1440 -or -cmin 1440" ;; cron.weekly) TIME="-cmin +10080 -or -cmin 10080" ;; cron.monthly) NOW=`date +%s` LASTMONTH=`date -d "last month" +%s` DIFF=`expr '(' $NOW - $LASTMONTH ')' / 86400` TIME="-ctime +$DIFF" ;; esac # remove all lock files for scripts that are due to run eval find $SPOOL/$BASE $TIME | \ xargs --no-run-if-empty rm } if test ! -e $SPOOL/$BASE ; then # accept this dir, if it isn't empty LIST=`find $CRONDIR ! -type d` if [ ! -z "$LIST" ] ; then RUN="${RUN} ${TIME_EXT}" fi fi As you can see, the flag file cron.daily is removed unconditionally if the ctime is longer than 1440 minutes ago. If the file doesn't exist any more afterwards, the interval ($TIME_EXT is hourly, daily, ...) is added to the list of directories to run (in $RUN). No variable like DAILY_TIME is involved in this computation. So, I'd like to ask for an explanation where $DAILY_TIME is involved in the run of cron.daily scripts, as I can't see it. Best, Joachim -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Joachim Schrod Email: jschrod@acm.org Roedermark, Germany