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.

Are there any crontab interface "shortcuts" in any (compatible/compliant) version of cron? We run some scripts with a regular interval, but offset.

I dislike lines like this;

3,8,13,18,23,28,33,38,43,48,53,58 * * * * command

I believe I have tried something like;

3/5 * * * * command
and
*/5+3 * * * * command before to no avail.

Is there any way to normalize/shrink cron entries with offset schedules such as the above?

share|improve this question
add comment

2 Answers

up vote 10 down vote accepted
3-59/5 * * * * command

Should start the job at 3 minutes after the hour and run it every 5 minutes until 59 minutes after the hour.

share|improve this answer
add comment

*/5 will get you every 5 min

3-58/5 should get you every 5 min starting at 3

http://www.nncron.ru/help/EN/working/cron-format.htm

share|improve this answer
    
Your source is GREAT, but aggravating that the answer to my question is not in one of the block-level examples, but is just a paragraph. (This has nothing to do with your answer, just vocalizing a chuckle I had when reading.) –  VxJasonxV Oct 7 '10 at 21:24
add comment

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.