Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

定时任务执行时间不正确并重复执行 #168

Closed
uprightzy opened this issue Mar 31, 2020 · 1 comment
Closed

定时任务执行时间不正确并重复执行 #168

uprightzy opened this issue Mar 31, 2020 · 1 comment

Comments

@uprightzy
Copy link

uprightzy commented Mar 31, 2020

最近发现定时任务在一个时间点附近会重复执行两次,配置个测试任务,每分钟跑一次(0 * * * * *),如下,本来应该在10:31分整执行的任务却在10:30:58开始执行,10:31分时又执行了一次。
image

@uprightzy
Copy link
Author

已经解决了,和cronsun无关。是结点的时钟不准问题。结点没有配ntpd服务,cronjob里每10分钟ntpdate同步一次,所以每10分钟会出现执行两次的问题。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant