Today is November 1st 2016 or in (unambiguous) numerals, 2016-11-01.
I have a user cron job set up like this:
# m h dom mon dow command
33 3 1 */2 * /home/user/...
It is supposed to run every other month on the first of the month at 3:33am, no matter what day of week that is, but for some reason it was run today, even though 11 is not divisible by 2.
Can someone explain me this? Is my assumption of divisibility by 2 wrong?
EDIT: I forgot to mention, I am running cron
version "3.0pl1-127+deb8u1" on a Debian 8.6 "Jessie" machine.
Best Answer
The
/
is not an arithmetic expression, instead it describes "step values" over the allowed range of values. So, since months always start with1
instead of0
,/2
would mean "take every other value", resulting in (1, 3, 5, 7, 9, 11).This is also decribed in the manual page, although this is not terrible clear and easy to understand: