PDA

View Full Version : messages from Cron Daemon



octeto
03-25-2008, 01:22 PM
Every minute the Cron Daemon sends this message:

cat: /usr/local/directadmin/data/task.queue: No such file or directory

The task.queue does'nt exist. How I can stop this ?

Thanks,

floyd
03-25-2008, 01:47 PM
who is it sending it to?

octeto
03-25-2008, 01:56 PM
View Full Header:

From: root@KAYU.*** (Cron Daemon)
To: root@KAYU.***
Subject: Cron <root@KAYU> cat /usr/local/directadmin/data/task.queue > /usr/local/directadmin/plugins/pgsql/include/task.queue
X-Cron-Env: <SHELL=/bin/sh>
X-Cron-Env: <HOME=/root>
X-Cron-Env: <PATH=/usr/bin:/bin>
X-Cron-Env: <LOGNAME=root>
X-Cron-Env: <USER=root>
Message-Id: <E1JeEuH-00066X-9G@KAYU.***>
Date: Wed, 26 Mar 2008 03:34:01 +0800

floyd
03-25-2008, 02:04 PM
Why is there a cron job for root doing this:

cat /usr/local/directadmin/data/task.queue > /usr/local/directadmin/plugins/pgsql/include/task.queue

It looks like you set this up for the root user. You should be able to put the MAILTO="" at the top or root's cron jobs to prevent it from sending you mail.

nobaloney
03-27-2008, 07:41 PM
Was that line added by a postgresql installation of some kind? It's going to error a lot, because the task.queue file is designed to not exist most of the time.

If you require this line, then change it to look like this:

cat /usr/local/directadmin/data/task.queue > /usr/local/directadmin/plugins/pgsql/include/task.queue 2> /dev.null
I wouldn't change the MAILTO; you may need something it mails some day.

Jeff

blasty
04-02-2008, 08:39 AM
Jeff, isn't that "fix" going to cause any nasty race conditions? Where the PGsql task file gets truncated before it's actually been taken care of ? Or will the output not get redirected if cat doesn't return 0 ?

nobaloney
04-21-2008, 06:38 PM
Untried. Don't know.

Jeff