nagios - 'notify-by-sms'

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
kico
Posts: 2
Joined: Thu May 31, 2012 3:51 am

nagios - 'notify-by-sms'

Post by kico »

Please help,

Nagios working ok, everything is ok but 'notify-by-sms' no delivered sms at phone.... i used gsm-utils.... phone is connected via usb
i can send sms from PC with this line: gsmsendsms -d /dev/ttyACM0 +329...... "TEST"...
Thanks :)
LHammonds
Posts: 23
Joined: Mon Jan 02, 2012 9:03 pm
Location: Behind you!!!

Re: nagios - 'notify-by-sms'

Post by LHammonds »

My phones allow sending an email to a text service so I just have my server send an email to [email protected] and I get text alerts that way.

My notifications are sent using the "sendemail" package on Ubuntu.

Here is a copy of my send command in commands.cfg

Code: Select all

define command{
        command_name    notify-host-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/sendemail -s 192.168.1.1:25 -f "Nagios <[email protected]>" -t $CONTACTEMAIL$ -u "** $NOTIFICATIONTYPE$ Host Alert: $HOSTNAME$ is $HOSTSTATE$ **"
        }
kico
Posts: 2
Joined: Thu May 31, 2012 3:51 am

Re: nagios - 'notify-by-sms'

Post by kico »

problem is resolved....
need a permission ttyACM0 for nagios user....

chown nagios /dev/ttyACM0
chmod 666 /dev/ttyACM0

:)
agriffin
Posts: 876
Joined: Mon May 09, 2011 9:36 am

Re: nagios - 'notify-by-sms'

Post by agriffin »

Glad you got things figured out!
Locked