[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Cron problem



This only started a week or two ago:  I've been getting emails from the
cron daemon indicating a problem with /etc/crontab or cron itself.  I've
tried using crontab to regenerate /etc/crontab, and purging and
reinstalling cron, and but am still getting the following:

From: Cron Daemon <root@suspectdevice.dyndns.org>
To: ludwig@suspectdevice.dynpurging and reinstalling, and dns.org
Subject: Cron <ludwig@suspectdevice> root        test -e
/usr/sbin/anacron || run-parts --report /etc/cron.daily
X-Cron-Env: <SHELL=/bin/sh>
X-Cron-Env:
<PATH=$PATH:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin>
X-Cron-Env: <HOME=/home/ludwig>
X-Cron-Env: <LOGNAME=ludwig>
[...]
/bin/sh: line 1: root: command not found
/etc/cron.daily/5snort:
find: /var/log/snort: Permission denied
/etc/cron.daily/acct:
savelog: directory /var/account is not writable
[etc, other failures due to permission denied]


/etc/crontab, which AFAICT is the default one that's been here all
along, reads as follows:

# /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.
# This file also has a username field, that none of the other crontabs
do.

SHELL=/bin/sh
PATH=$PATH:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin

# m h dom mon dow user  command
25 6    * * *   root    test -e /usr/sbin/anacron || run-parts --report
/etc/cron.daily
47 6    * * 7   root    test -e /usr/sbin/anacron || run-parts --report
/etc/cron.weekly
52 6    1 * *   root    test -e /usr/sbin/anacron || run-parts --report
/etc/cron.monthly


Why is cron suddenly taking the "root" argument as a command instead of
the username to run the following commands as?  I can't think of
anything I've installed or changed recently that might have sparked this
problem.

-- 
Public key -- http://superdeluxe.com/~ludwig/publickey



Reply to: