Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

syslog fills up the root's mail 1

Status
Not open for further replies.

MoshiachNow

IS-IT--Management
Feb 6, 2002
1,851
IL
HI,

I have the following syslog:
====================================================
cat syslog.conf
*.err;kern.debug;user.none /dev/console
#
# syslog configuration file.
#
# Note: Have to exclude user from most lines so that user.alert
# and user.emerg are not included, because old sendmails
# will generate them for debugging information. If you
# have no 4.2BSD based systems doing network logging, you
# can remove all the special cases for "user" logging.
#
*.err;kern.debug;daemon,auth.notice;mail.crit;user.none /usr/adm/messages

*.alert;kern.err;daemon.err;user.none operator
#*.alert;user.none root

*.emerg;user.none *

# for loghost machines, to have authentication messages (su, login, etc.)
# logged to a file, un-comment out the following line and adjust the file name
# as appropriate.
#
# if a non-loghost machine chooses to have such messages
# sent to the loghost machine, un-comment out the following line.
#
#auth.notice /usr/spool/log/authlog

#mail.debug /usr/spool/log/syslog

# following line for compatibility with old sendmails. they will send
# messages with no facility code, which will be turned into "user" messages
# by the local syslog daemon. only the "loghost" machine needs the following
# line, to cause these old sendmail log messages to be logged in the
# mail syslog file.
#
user.alert /usr/adm/messages
lpr.debug;lpr.info;lpr.warning /usr/adm/messages
====================================================
I have masked out messenging to root,in order not to receive mails to root on every su (I have a crontab script that does "su" every minute).
This did not help much - my /var/spool/mail/root file grows every minute,getting the following inside:
==================================================
*****************************************************************
cron: The previous message is the standard output
and standard error of one of the cron commands.

From daemon Sun Jul 23 16:19:00 2006
Received: (from daemon@localhost) by syslab11.cil.xxx.com (AIX5.2/8.11.6p2/8.11.0) id k6NLJ0J38464 for root; Sun, 23 Jul 2006 16:19
:00 -0500
Date: Sun, 23 Jul 2006 16:19:00 -0500
From: daemon
Message-Id: <200607232119.k6NLJ0J38464@syslab11.cil.creo.com>
To: root

*.err;kern.debug;user.none /dev/console

*****************************************************************
cron: The previous message is the standard output
and standard error of one of the cron commands.
================================================

Would appreciate advises on how to stop getting mail to root from cron.
My line in crontab looks like:
0 * * * * /version/scripts/kill_unknown.sh

Thanks


Long live king Moshiach !
 
One option is to change the cron entry:
0 * * * * /version/scripts/kill_unknown.sh > /dev/null 2>&1

&quot;If you always do what you've always done, you will always be where you've always been.&quot;
 
Thanks rzs0502 :)

now i know why most of our crontabs are pointing to /dev/null :)

Make sense :)

Regards,
Khalid
 
Ooops ...
Does work - did try it 2 days ago,but did a mistake sticking the ">/dev/null 2>&1" at the wrong line ... :)

Long live king Moshiach !
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top