Specifying “all odd values” in crontab?

前端 未结 6 798
孤城傲影
孤城傲影 2020-12-08 12:37

In crontab, I can use an asterisk to mean every value, or \"*/2\" to mean every even value.

Is there a way to specify every odd value? (Would someth

6条回答
  •  广开言路
    2020-12-08 13:18

    I realize this is almost 10 years old, but I was having trouble getting 1-23/2 for an every two hour, odd hour job.

    For all you users where, exact odd hour precision is not needed. I did the following which suited my teams needs.

    59 */2 * * *
    

    Execute the job every two hours, at the 59th Minute.

提交回复
热议问题