当前位置: 技术问答>linux和unix
crontab每月一号定时启动程序,启不来
来源: 互联网 发布时间:2015-07-18
本文导语: 我的程序内容: # DO NOT EDIT THIS FILE - edit the master and reinstall. # (/tmp/crontab.3499 installed on Wed Aug 25 11:10:52 2004) # (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $) * * 1 * * /sbin/delonemonth 已经...
我的程序内容:
# DO NOT EDIT THIS FILE - edit the master and reinstall.
# (/tmp/crontab.3499 installed on Wed Aug 25 11:10:52 2004)
# (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
* * 1 * * /sbin/delonemonth
已经把delonemonth考到了/sbin/下,但是我把系统时间改成某个月1号时,程序并未被调用!
# DO NOT EDIT THIS FILE - edit the master and reinstall.
# (/tmp/crontab.3499 installed on Wed Aug 25 11:10:52 2004)
# (Cron version -- $Id: crontab.c,v 2.13 1994/01/17 03:20:37 vixie Exp $)
* * 1 * * /sbin/delonemonth
已经把delonemonth考到了/sbin/下,但是我把系统时间改成某个月1号时,程序并未被调用!
|
好象不能只给* * 1 * *吧,我觉得至少也要指定个时分,给个30 12 1 * *看看12点30分是否执行(猜测,手头无环境)
|
是不是0点执行的,那把日期改到31的23点59分呢
|
1. Check if you setup it by using the command "crontab -e"? If not, you should setup it by that command wihle not directly modify the relational configuration file.
2. Check if /sbin/delonemonth file has the privilege of execution.
2. Check if /sbin/delonemonth file has the privilege of execution.
|
你这个需求用
anacron
似乎更好点
anacron
似乎更好点