Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I've had the cron service off for 24 hours and would like to start it. I'm worried that it might fire off a process that was missed while it was off. I don't want those missed jobs to run until they're next scheduled time. Is cron's normal behavior to start any jobs it missed while it was offline? I'm running CentOS 5.5 x86-64.

share|improve this question

1 Answer 1

There are several different varieties of cron, such as vixie-cron, anacron, hc-cron, etc. The differences between them often have to do with how they handle missed jobs.

That being said, most crons do not keep track of anything while the machine is up but the cron daemon is turned off. They should only resume service at the time you start the daemon. The only jobs they should go back and run are the few cron daemons that support makings sure jobs get run even if the machine was powered down at the time. If you turned the cron service off yourself, you shouldn't have to worry about it going back and re-running past jobs.

share|improve this answer
    
To elaborate a bit on Caleb's answer: Vixie-cron doesn't care how long the machine was off: It will just start running jobs as scheduled. anacron is a cron supplement that will attempt to run "missed" jobs (I'm not sure about it's logic: I don't run it myself). hc-cron will attempt to "catch-up" jobs that didn't run because the computer was shut down -- again, as I don't use it I'm not sure how smart it is about the catch-up process. –  voretaq7 Apr 13 '11 at 15:09

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.