The Phenomenon of the Cron
As WebBasedCron has become bigger, and more people have been setting cron jobs, I’ve begun to notice a strange pattern. If someone wanted to set a cron job to run, say every hour, they would generally choose the start of the hour as the trigger time. This is ok in theory, but when everyone does this, it causes a huge load on the server at specific points in time.
I monitored the number of cron jobs run every minute, for a one week period. The plot below shows the number of cron jobs run every minute of a given hour. This is averaged over a one week period, but it shows what I’m talking about. You can see that on the hour, half hour, and every 15 minutes, people generally set their cron jobs to run.
The thing is that if a cron job was to run ever 15 minutes of each hour, it could be set to run on the 3rd minute, the 18th minutes, 33rd minute, etc. rather than 0, 15, 30, etc.
So next time anyone wants to set a cron job, and you want it to run once and hour, just choose a random minute, rather than 0.
Have a second? Check out this great Canadian Health & Living Store based in Toronto

