4 ms·
This works, but compared to using systemd it has the drawback that the range of possible times is anchored to the configured time in cron. The systemd timer exa
by TimWolla 6y ago
This works, but compared to using systemd it has the drawback that the range of possible times is anchored to the configured time in cron. The systemd timer example I gave causes the next cycle to start when the previous job finished.
So if it initially runs the script between 0:00 and 1:00 and the script takes 1.5 hours to finish then the next run will be between 1:30 and 2:30 the next day, instead of 0:00 and 1:00.
- MayeulC 6y ago> So if it initially runs the script between 0:00 and 1:00 and the script takes 1.5 hours to finish then the next run will be between 1:30 and 2:30 the next day Shouldn't it be between 1:30 ans 3:30? I'm just nitpicking, of course, that's a nice solution.
- TimWolla 6y agoYes, you are correct. The script ends no later than 2:30 and then there's a delay of up to 1 hour.