*/15 * * * *
works fine by running every 15 minutes starting from the top of the hour.
I need a task to run every 15 minutes starting from 5 minutes past the hour. Several cron simulators, eg this, say it should be 5/15 * * * *
, but when I use that, nothing runs.
What should be the proper syntax?
Either try @jones0610's suggestion, or this one:
I think 5/15 will run only once per hour, at 5 minutes past the hour.
This will cause your script to run every 15 minutes starting at 5 minutes past the hour. Hope this helps.
crontab:
5,20,35,50 * * * *
The man page crontab(5) from the package
cron
says:It doesn't say ranges could be used with single values, so indeed
5/15
doesn't appear valid. (Even if we took it to mean every fifteen minutes within the degenerate one-value range, it'd still be just the same as just5
and using it would be silly.)There may be other implementations, but I believe that's the one installed by default on Ubuntu. In any case, it often pays off to consult the documentation of the software you're using instead of random internet resources which may neglect to mention the scope their explanations are valid in.