Re: question about a cron job

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 2005-01-17 at 09:01, Erwin Kerk wrote:
> Al wrote:
> > I've got a question about the following cronjob.
> > 
> >>
> >> #At 3:01 our time, run backups
> >> 1 0 * * * /usr/local/bin/php 
> >> /www/r/rester/htdocs/auto_backup/back_em_up.php 
> >> >/www/r/rester/htdocs/auto_backup/cron.log 2>&1
> >>
> >> #At 3:02 clean up sessions folder
> >> 2 0 * * * (find /www/r/rester/htdocs/sessions/ -name 'sess_*' -mtime 
> >> +1 -delete)
> >>
> >> #this is only for testing a new cronjob, every minute
> >> * * * * * /usr/local/bin/php 
> >> /www/r/rester/htdocs/phpList_cronjob/process_cronjob.php 
> >> >>/www/r/rester/htdocs/phpList_cronjob/cron.log 2>>&1
> >>
> > 
> > The new one doesn't seem to want to run until after 3:01 or 3:02.  
> > Shouldn't the sever just run it every minute?
> > 
> > And, the every minute job doesn't add anything to its log file.
> > 
> > Apache on a virtual host.  The 3:01 and 3:02 jobs have been running fine 
> > for months.
> > 
> > Thanks
> > 
> 
> The CRON daemon only refreshes it's job list after a job in the current 
> list is completed. Therefore, the CRON daemon won't notice the 
> "every-minute" job until 3.01 pm.
> 

I am not sure I read that correctly.  Are you saying that the job cannot
be running for the new crontab to be installed?  If so, I could see that
althought I have never experienced it.  

If you are saying that each job in the crontab must be run before the
new crontab is completed, then I believe you are in error.  I have often
changed crontab entries to test how a job will operate in the cron
environment and never experienced any delay on the acceptance of the new
job even though I have hourly and daily jobs there.

Bret

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux