Error: Cron emails root
I got postfix working on my box yesterday.. And I noticed this:
From nobody Thu Nov 8 22:01:00 2001
Return-Path: <[email protected]>
Delivered-To: <a href="mailto:[email protected]" class="bb-email">[email protected]</a>
Received: by host.maxalbert.com (Postfix, from userid 0)
id 6EFC83BE25; Thu, 8 Nov 2001 22:01:00 -0800 (PST)
From: <a href="mailto:[email protected]" class="bb-email">[email protected]</a> (Cron Daemon)
To: <a href="mailto:[email protected]" class="bb-email">[email protected]</a>
Subject: Cron <root@host> run-parts /etc/cron.hourly
X-Cron-Env: <SHELL=/bin/bash>
X-Cron-Env: <PATH=/sbin:/bin:/usr/sbin:/usr/bin>
X-Cron-Env: <MAILTO=root>
X-Cron-Env: <HOME=/>
X-Cron-Env: <LOGNAME=root>
Message-Id: <[email protected]>
Date: Thu, 8 Nov 2001 22:01:00 -0800 (PST)
touch: /var/log/news/nntpsend.log: Permission denied
chmod: /var/log/news/nntpsend.log: Permission denied
/usr/bin/nntpsend: /var/log/news/nntpsend.log: Permission denied
What are those errors? And how can I fix them?
Is it normal for Cron to email root like this?
Mark Hensler
If there is no answer on Google, then there is no question.
mairving posted this at 11:15 — 9th November 2001.
They have: 2,256 posts
Joined: Feb 2001
I would say just off the top of my head that you should check the permissions of the directory. It sounds like the user, news, is trying to write to that directory but doesn't have permission.
Mark Irving
I have a mind like a steel trap; it is rusty and illegal in 47 states
Mark Hensler posted this at 16:48 — 9th November 2001.
He has: 4,048 posts
Joined: Aug 2000
[root@host /root]# cd /var/log/news
[root@host news]# ls -la
total 376
drw-r----- 3 root adm 4096 Nov 4 04:02 ./
drwxr-xr-x 15 root root 4096 Nov 4 04:02 ../
drwxrwxr-x 2 news news 4096 Apr 12 2001 OLD/
-rw------- 1 news news 9188 Nov 9 08:01 errors
-rw------- 1 news news 571 Nov 4 04:02 errors.1.gz
-rw------- 1 news news 586 Oct 28 04:02 errors.2.gz
-rw------- 1 news news 575 Oct 21 04:02 errors.3.gz
-rw------- 1 news news 568 Oct 14 04:02 errors.4.gz
-rw------- 1 news news 580 Oct 7 04:02 errors.5.gz
-rw------- 1 news news 13379 Nov 9 08:01 info
-rw------- 1 news news 931 Nov 4 04:02 info.1.gz
-rw------- 1 news news 937 Oct 28 04:02 info.2.gz
-rw------- 1 news news 928 Oct 21 04:02 info.3.gz
-rw------- 1 news news 930 Oct 14 04:02 info.4.gz
-rw------- 1 news news 935 Oct 7 04:02 info.5.gz
-rw-rw-r-- 1 news news 88124 Nov 9 08:01 news.crit
-rw-rw-r-- 1 news news 1138 Nov 7 20:29 news.err
-rw-rw-r-- 1 news news 89608 Nov 9 08:01 news.notice
-rw------- 1 news news 86 Nov 7 20:29 warnings
-rw------- 1 news news 31 Oct 28 04:02 warnings.1.gz
-rw------- 1 news news 31 Oct 21 04:02 warnings.2.gz
-rw------- 1 news news 31 Oct 14 04:02 warnings.3.gz
-rw------- 1 news news 31 Oct 7 04:02 warnings.4.gz
-rw------- 1 news news 31 Sep 30 04:02 warnings.5.gz
Mark Hensler
If there is no answer on Google, then there is no question.
netcommr posted this at 21:30 — 9th November 2001.
They have: 8 posts
Joined: Nov 2001
you can change the cron job to run as 'root', or change the 'group' of that directory to the 'user' the cron job is running as and chmod (664) to allow writing by group, or change the 'owner' of that directory to the 'user' the cron job is running as
http://www.KeywordDelivery.com
A dynamic response content delivery and management system which allows any web page to display content targeting the visitors interest based on the referrer.
Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.