email notifications

Carlos Sánchez cjsanz4job at hotmail.com
Mon Dec 4 14:48:20 CET 2006


Hi Abegal!

When you install nagios, there are any commands(commands.cfg file) that was 
created by default(host-notify-by-email and notify-by-email) this commands 
sends notifications by mail, this commands must be asociated with a 
contacts(contacts.cfg)

You must to read the nagios manual for the specific information, this 
information is a first step

define command{
command_name    host-notify-by-email
command_line    /usr/bin/printf "%b" "***** Nagios  *****\n\nNotification 
Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress: 
$HOSTADDRESS$\nInfo: $HOSTOUTPUT$\n\nDate/Time: $LONGDATETIME$\n" |  
/usr/bin/mail -s "Host $HOSTSTATE$ alert for $HOSTNAME$!" $CONTACTEMAIL$
}

define command{
command_name    notify-by-email
command_line    /usr/bin/printf "%b" "***** Nagios  *****\n\nNotification 
Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: 
$HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: 
$LONGDATETIME$\n\nAdditional Info:\n\n$SERVICEOUTPUT$" |  /usr/bin/mail -s 
"** $NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ 
**" $CONTACTEMAIL$
}


>From: Abegail Pungtilan <abe_pungtilan at yahoo.com>
>To: nagios-users at lists.sourceforge.net
>Subject: [Nagios-users] email notifications
>Date: Thu, 30 Nov 2006 21:50:19 -0800 (PST)
>
>Dear All,
>
>I'm new to nagios world with basic knowledge in unix. My boss ask me to 
>enable setup email notifications on our nagios and I'm having a hard time 
>how / where to start. Could someone give me hints / tips on this it would 
>be highly appreciated?
>
>Many thanks.
>
>
>
>
>Regards,
>
>Abegail B. Pungtilan
>Data Networks Section
>NOD / CNOD
>Digitel Mobile Philippines Inc.
>Tel no. +63 397 8619
>Mobile no. +63 922 9425 836
>
>---------------------------------
>Access over 1 million songs - Yahoo! Music Unlimited.


>-------------------------------------------------------------------------
>Take Surveys. Earn Cash. Influence the Future of IT
>Join SourceForge.net's Techsay panel and you'll get the chance to share 
>your
>opinions on IT & business topics through brief surveys - and earn cash
>http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV


>_______________________________________________
>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

_________________________________________________________________
Talk now to your Hotmail contacts with Windows Live Messenger. 
http://clk.atdmt.com/MSN/go/msnnkwme0020000001msn/direct/01/?href=http://get.live.com/messenger/overview


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
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