[TriLUG] bash script execution time

Rick DeNatale rick.denatale at gmail.com
Fri Jul 8 18:17:44 EDT 2005


On 7/8/05, Shane O'Donnell <shaneodonnell at gmail.com> wrote:
> crontab allows for both ranges and intervals:
> 
> */15 2-23 * * * command
> 
> should get you close, but it doesn't address the :30 requirement.

No reason you can't have more than one crontab file entry for the command.

# run at 0230 and 0245
30,45 2 * * * command
# run every 15 minutes between 0300 and 2200
*/15 3-22 * * * command
# run at 2300, 2315 and 2330
0,15,30 23 * * * command

It wasn't clear if you actually wanted to run at 0230 and 2330 or not,
this does, but the changes required to exclude the end-points should
be obvious.



More information about the TriLUG mailing list