gnokii-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Nagios/Groundwork's issue


From: Guido Falsi
Subject: Re: Nagios/Groundwork's issue
Date: Wed, 23 Sep 2009 23:13:51 +0200
User-agent: Thunderbird 2.0.0.23 (X11/20090823)

Martyn wrote:
I would like to thank you for your response firstly but I need to ask..
Looking at the Nagios code below; how would I formulate a meaningful Nagios
alert using Gnokii.

Thanks

Martyn

-----Original Message-----
From: address@hidden
[mailto:address@hidden On Behalf Of
Daniele Forsi
Sent: 23 September 2009 17:26
To: Discussion forum for gnokii users.
Subject: Re: Nagios/Groundwork's issue

2009/9/23 Martyn:

Here is my Nagios Command:

/usr/bin/printf "%.120s" "ALERT\n\nNotification Type:
$NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress:
$HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time:
$LONGDATETIME$\n\nAdditional Info:\n\n$SERVICEOUTPUT$ ##" | gnokii --sendsms "** $NOTIFICATIONTYPE$ alert - $HOSTALIAS$/$SERVICEDESC$ is$SERVICESTATE$ **" $CONTACTEMAIL$ -r

I Do use Nagios at work, but not with gnokii, and don't know what Groundwork is, but I think you could have more luck is you use the smsd included with nagios. For best results I'd suggest interfacing it to nagios using the MySQL or PostgreSQL(depending on your personal preference or what you have available) module.

Using an SQL table would avoid you directory permission problems and other things. Making an SH script to fill the table with the SMSes to send should be quite easy, just be sure to sanitize any data you put there in your script.

--
Guido Falsi <address@hidden>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]