Bug 139148 - stderr output not sent to /dev/null
Summary: stderr output not sent to /dev/null
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: webalizer
Version: 2
Hardware: i386
OS: Linux
medium
low
Target Milestone: ---
Assignee: Joe Orton
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-11-13 06:33 UTC by Jeff Thompson
Modified: 2008-05-01 15:38 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2005-06-21 15:44:29 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Jeff Thompson 2004-11-13 06:33:05 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.5)
Gecko/20041107 Firefox/1.0

Description of problem:
Hi, /etc/cron.daily/00webalizer attempts to redirect stdout and stderr
output to /dev/null, however, I still get email from cron jobs when
webalizer encounters errors.

Changing 00webalizer to redirect stderr *after* the redirection of
stdout seems to work. The diff below seems to correct the problem:

--- 00webalizer.old     2004-11-13 00:32:17.913876850 -0600
+++ 00webalizer 2004-11-13 00:19:09.246975466 -0600
@@ -2,7 +2,7 @@
 # update access statistics for the web site

 if [ -s /var/log/httpd/access_log ] ; then
-    /usr/bin/webalizer 2>&1 > /dev/null
+    /usr/bin/webalizer > /dev/null 2>&1
 fi

 exit 0

Let me know if you have any questions. 

Thanks,

Jeff



Version-Release number of selected component (if applicable):
webalizer-2.01_10-22

How reproducible:
Sometimes

Steps to Reproduce:
1. /etc/cron.daily/00webalizer runs via cron
2.
3.


Actual Results:  Email is sent by cron if webalizer encounters
over-size log records and writes warning messages to stderr.

Expected Results:  00webalizer attempts to redirect stdout & stderr to
/dev/null, which should prevent any output from the cron job.

By changing the order of the redirection as shown in the diff, both
stdout and stderr are sent to /dev/null and cron does not send email.

Additional info:

Comment 1 Matthew Miller 2005-04-26 16:23:29 UTC
Fedora Core 2 is now maintained by the Fedora Legacy project for
security updates only. If this problem is a security issue, please
reopen and reassign to the Fedora Legacy product. If it is not a
security issue and hasn't been resolved in the current FC3 updates or
in the FC4 test release, reopen and change the version to match.

Comment 2 Joe Orton 2005-06-21 15:44:29 UTC
[This is a mass bug update]

Fedora Core 2 is now maintained by the Fedora Legacy project for
security updates only. If this problem is a security issue, please
reopen and reassign to the Fedora Legacy product. If it is not a
security issue and hasn't been resolved in the current FC3 or FC4 updates,
reopen and change the version to match.


Note You need to log in before you can comment on or make changes to this bug.