1

I'm getting ready to launch a crontab, but since I'm new at it, wanted to check with someone if they could verify that what I'm doing is correct.

* 3 * * 5 /usr/local/bin/backup.bash

The above crontab line will run my backup bash file EVERY Friday at 3 a.m., is that correct? I need it to run every Friday, not just one Friday and then stop.

1 Answer 1

1

You need to add 00 (or 0) to the minute(s) field, otherwise it will be run for each minute from 03:00 to 03:59 on every friday.

So, to run the job at 03:00 AM every friday:

00 03 * * 5 /usr/local/bin/backup.bash
2
  • You saved me there! See? That's why I'm glad I checked on Stack Exchange. Thank you.
    – GTS Joe
    Mar 20, 2016 at 3:22
  • @GTSJoe Glad i could help :)
    – heemayl
    Mar 20, 2016 at 3:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .