每2天安排一次Cron工作 [英] Schedule cron job every 2 days

查看:1345
本文介绍了每2天安排一次Cron工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们已经知道模式 * * / 2 * * * 每2小时执行一次任务,相似地可以 * * * / 2 * * 每2天(每2天执行一次)执行任务。如果是,那么什么时候执行任务?

As we already know that the pattern * */2 * * * executes the task for every 2 hour, similary can * * */2 * * execute the task for every 2 day (once in 2 days). If yes, at what time the task will be executed?

推荐答案

这是与该主题相关的数十篇文章的副本其中这是详尽的

This is a duplicate of dozen of posts about this topic, of which this exhaustive one.

0 0 2 * * :每个月的午夜2天。

0 0 * / 2 * * :每个月的第二个午夜。

0 0 2 * * : every 2 days at midnight, every month.
0 0 */2 * * : 2nd of the month at midnight, every month.

这篇关于每2天安排一次Cron工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆