Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My crontab runs a cron every 5 minutes... If the cron needs more than 5 minutes to run, can this be a problem?? Can the problem be with the commands the cron runs?

Thanks for your answer ;-)

share|improve this question

cron should have no problem running your task again even though the first one isn't finished.

Although, a problem could arise depending on the commands you are running (i.e. if they both write to the same file)

share|improve this answer
If having two instances of the script running concurrently is an issue, you want to use a lockfile - or things like pgrep to check if another instance is running - to either make the second instance wait or quit, if it detects another instance is running. – LawrenceC Sep 5 '12 at 11:03

Your Answer


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.