Skip to content

定时任务不定时执行该怎么办? #320

Answered by lan-tianxiang
jeymingwu asked this question in Q&A
Discussion options

You must be logged in to vote

docker定时没有执行,可以先检查一下定时任务是否正常,编写没问题的条件下,可以自写一个测试定时用于判断是软件问题还是系统问题。

在定时文件中加入以下内容

* * * * * echo $(date +%T) >> /root/jd/time.log

然后保存后,等待两分钟,看一下目录下是否有time.log文件生成

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@jeymingwu
Comment options

Answer selected by lan-tianxiang
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants