Nagios doesn't send any notification

Reynier Pérez Mira rperezm at uci.cu
Fri Sep 25 05:19:03 CEST 2009


Hi every:
I have installed and configured Nagios 3.2.0. For now I'm only check to 
servers. I want to receive e-mails when some of the services or server 
fail. For this I wrote this in the file commands.cfg under 
/usr/local/nagios/etc

define command{
         command_name    host-notify-by-email
         command_line    /usr/bin/mail -b "%b" "***** Nagios 
*****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: 
$HOSTS$
         }

define command{
         command_name    service-notify-by-email
         command_line    /usr/bin/mail -b "%b" "***** Nagios 
*****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: 
$SERVICEDESC$\nHost:$
         }

Then in the contacts.cfg file I define this section:
define contact{
         contact_name                    rperezm
         alias                           rperezm
         email                           rperezm at uci.cu
         service_notification_period     servers_hours
         host_notification_period        servers_hours
         service_notification_options    w,u,c,r
         host_notification_options       d,u,r
         service_notification_commands   notify-by-email
         host_notification_commands      host-notify-by-email
         }

My postfix is configured as Satellite so the mail is delivered to 
another Postfix but the address arrive empty. See this entry 
/var/log/mail.log:

Sep 22 10:34:14 monitoring postfix/qmgr[21860]: 30B911F58: 
from=<nagios at monitoring.prod.uci.cu>, size=786, nrcpt=1 (queue active)
Sep 22 10:34:14 monitoring postfix/cleanup[22149]: 3E6741F57: 
message-id=<20090922143414.3E6741F57 at monitoring.uci.cu>
Sep 22 10:34:14 monitoring postfix/qmgr[21860]: 3E6741F57: 
from=<nagios at monitoring.prod.uci.cu>, size=786, nrcpt=1 (queue active)
Sep 22 10:34:14 monitoring postfix/smtp[22157]: 30B911F58: to=<@b>, 
orig_to=<%b>, relay=10.128.50.1[10.128.50.1]:25, delay=0.16, 
delays=0.08/0.01/0.02/0.04, dsn=2.0.0, status=sent (250 2.0.0 Ok: queued 
as 3D94F35F4)
Sep 22 10:34:14 monitoring postfix/qmgr[21860]: 30B911F58: removed
Sep 22 10:34:14 monitoring postfix/smtp[22164]: 3E6741F57: to=<@b>, 
orig_to=<%b>, relay=10.128.50.1[10.128.50.1]:25, delay=0.14, 
delays=0.06/0.01/0.01/0.06, dsn=2.0.0, status=sent (250 2.0.0 Ok: queued 
as 4469F402B)
Sep 22 10:34:14 monitoring postfix/qmgr[21860]: 3E6741F57: removed

So, where is the problem?
Regards and thanks in advance

------------------------------------------------------------------------------
Come build with us! The BlackBerry® Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9-12, 2009. Register now!
http://p.sf.net/sfu/devconf
_______________________________________________
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