安装msktutil ,每天cron都会抱怨,我会收到带有文本的电子邮件:
run-parts: /etc/cron.daily/msktutil exited with return code 1
当我运行:
user@box:~$ sudo /etc/cron.daily/msktutil user@box:~$ echo $? 0
此外,如果我修改msktutil在详细模式下运行,没有什么是暴露的(它告诉我早点更改密钥表内容)。
我错过了哪些重要的testing来确定(非常痛苦的)问题?
/ etc / crontab文件是:
# /etc/crontab: system-wide crontab # Unlike any other crontab you don't have to run the `crontab' # command to install the new version when you edit this file # and files in /etc/cron.d. These files also have username fields, # that none of the other crontabs do. SHELL=/bin/sh PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin # mh dom mon dow user command 17 * * * * root cd / && run-parts --report /etc/cron.hourly 25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily ) 47 6 * * 7 root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.weekly ) 52 6 1 * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.monthly ) #
而msktutil是一个sh脚本:
cat /etc/cron.daily/msktutil #!/bin/sh test -x /usr/sbin/msktutil || exit 0 # These options are overridden in /etc/default/msktutil. # Edit there, not here. AUTOUPDATE_ENABLED="false" AUTOUPDATE_OPTIONS="" [ -r /etc/default/msktutil ] && . /etc/default/msktutil [ "$AUTOUPDATE_ENABLED" = "true" ] || exit 0 exec /usr/sbin/msktutil --auto-update $AUTOUPDATE_OPTIONS