Nagios Alert Format?

Engelmann, Austin aengelmann at libertymgt.com
Thu Feb 17 18:59:00 CET 2011


This is a small question. I have been editing the Nagios alert commands
to get a nice, simple format to our cell phones. I am trying to get the
notification type to be on the "MSG:" line. In my command, the
notification type always gets place on the next line. My current command
and the format of the SMS alert are listed below, anybody see what I can
change and if it's possible?

 

#'notify-service-by-email' command definition

define command{

                command_name   notify-service-by-email

                command_line      /usr/bin/printf "%b"
"$NOTIFICATIONTYPE$\nSVC: $SERVICEDESC$\nHost: $HOSTALIAS$\nState:
$SERVICESTATE$\n$SERVICEOUTPUT$" | /bin/mail -s "Service Alert"
$CONTACTEMAIL$

                }

 

FRM:nagiosadmin 

SUBJ:Service Alert

MSG:

RECOVERY

SVC: Ping Test

Host: Hostname

State: OK

PING OK - Packet loss = 0%,

RTA = 14.29 ms

 

Austin

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20110217/33e5286d/attachment.html>
-------------- next part --------------
------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
-------------- next part --------------
_______________________________________________
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