Notifications stopped

Chris Wilson chris at aidworld.org
Mon Feb 28 18:37:03 CET 2005


Hi all,

I have been using Nagios very successfully for a number of years.
However, one instance has started behaving strangely in the last few
weeks.

I first noticed it because notifications had stopped without any
explanation. Restarting Nagios caused them to come back, and I thought
little more of it until a week later, when it happened again.

I configured Nagios to log all output of the notify commands to a log
file, for example:

define command{
        command_name    notify-by-email
        command_line    /usr/bin/printf "%b" 'This is an automated alert
from the AidWorld website monitoring system\n(aka Nagios). The
$SERVICEDESC$ on $HOSTALIAS$ is now $SERVICESTATE$.\n\nNotification
Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState:
$SERVICESTATE$\nAddress: $HOSTADDRESS$\nDate/Time:
$DATETIME$\nAdditional Info:\n\n$OUTPUT$' | /bin/mail -s '[NAGIOS]
Alert: $HOSTALIAS$ $SERVICEDESC$ is $SERVICESTATE$' $CONTACTEMAIL$
>>/usr/local/nagios/var/notify.out 2>&1
        }

The file notify.out was created, but nothing written to it. So I left
nagios running... and again notifications stopped, about a week later.

I couldn't find any errors in the notify.out file. nagios.log says that
a notification was sent to each contact, but the system mail logs show
no record of it. Mail configuration works, I can send email using
/bin/mail and it does appear in /var/log/maillog.

How can I go about diagnosing this problem further? Could Nagios itself
capture the standard output and error from notification plugins and log
it to syslog or the Nagios log file? That would make diagnosing problems
like this much easier, in my opinion.

Thank you all in advance for your help.

Cheers, Chris.
-- 
(aidworld) chris wilson | chief engineer (chris at aidworld.org)



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list