I want to set a cronjob entry that runs a script every 30 minutes from 9:00 to 18:00 but I do not want it to run at 18:30. The script should run for the first time at 9:00 and for the last time at 18:00. Is this possible?
Tell me more
×
Unix & Linux Stack Exchange is a question and answer site for
users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.
|
However, the above will run at 18:30. So, you're best bet is to have a separate job to handle 18:00. So:
Also, Cron job generators are awesome. |
|||||
|
|
Or do an extra test before firing the script. In the example below I test if current is less than 1815.
|
|||
|
|
