[hobbit] SMS +additional messages
Gary Baluha
gumby3203 at gmail.com
Thu Feb 15 21:40:54 CET 2007
I wrote my own external Hobbit script to provide a more detailed SMS output,
but is still shorter than the regular email alerts. It's really short, so
I've copy/pasted it below:
<SCRIPT>
#!/bin/bash
msg=`echo "${BBALPHAMSG}" | egrep "&yellow|&red"`
msg="\n${msg}"
# CODE:
#=======
subject="!HB ${ACKCODE}"
alert="${BBHOSTSVC} ${BBCOLORLEVEL}"
message="\n${alert}${msg}"
echo -e "${message}" | mail -s "${subject}" $RCPT
</SCRIPT>
To use this, you replace
MAIL [recipients] [flags]
with
SCRIPT [hobbit home]/server/ext/oursms [recipients] [flags]
where "[hobbit home]" is the Hobbit home directory, and "oursms" is the name
of the script above. You can of course name it whatever you want.
Essentially, this does what FORMAT=SMS does, except that it also displays
the items that are red. Also, if you use the above script, make sure you
don't include FORMAT=SMS.
Hello,
>
> I am rolling my monitoring over to sending email text messages to cell
> phones using the SMS format option.
> This works great :-)
>
> but.......
> Some of the users would like some more information in the message, how
> can I include some additional parameters...
> Specifically, when i am using DEVMON and the if_stat monitor status. It
> comes in the normal email formatting, but not in SMS.
>
> thanks, michael
>
>
> --
>
> Michael A. Price
> Performance Network Engineering
> NASA/GSFC Code 440.8/LMB
> Greenbelt, Maryland 20770
> Phone: 240-684-1356
> Cell: 410-507-7476
> e-mail: mprice at hst.nasa.gov
> ----------------------------------------------
>
>
> To unsubscribe from the hobbit list, send an e-mail to
> hobbit-unsubscribe at hswn.dk
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xymon.com/pipermail/xymon/attachments/20070215/f6736824/attachment.html>
More information about the Xymon
mailing list