Hi,
I know that SMS-Client is not supported in nagios. I hope there are more admins here that are using SMS-Cient that may can help me.
I installed the sms_Client acoording the manual.
If i sent an sms in the linux prompt. it goes successfully.
[root@localhost ~]# /bin/sms_client kpn:06xxxxxxxx "Test message"
Dialing SMSC 0653151515...
WARNING: read() Timeout
Connection Established.
Hangup...
kpn Service Time: 37 Seconds
[000] kpn:06xxxxxxxx "Test message"
Total Elapsed Time: 37 Seconds
[root@localhost ~]#
in the commands.cfg i’f added the flowing rules:
# 'notify-by-pager' command definition
define command{
command_name notify-by-pager
command_line /bin/sms_client -q kpn:06xxxxxxxx " $NOTIFICATIONTYPE$: $HOSTNAME$: $SERVICEDESC$ is $SERVICESTATE$"
}
# 'host-notify-by-pager' command definition
define command{
command_name host-notify-by-pager
command_line /bin/sms_client -q kpn:06xxxxxxxx "VDCnrw $NOTIFICATIONTYPE$: $HOSTNAME$ is $HOSTSTATE$"
}
and the service is defined like this
define service{
use generic-service ; Name of service template to use
host_name "Switch name"
service_description CISCO Chassis Environment Check
is_volatile 0
check_period 24x7
max_check_attempts 2
normal_check_interval 2
retry_check_interval 1
contact_groups admins
notification_options w,u,c,r
notification_interval 960
notification_period 24x7
check_command check_cisco
}
all should be alright
If i pull the powersupply of the switch
and i check the nagios log i see the following:
Warning: Attempting to execute the command “/usr/bin/sms_client -q kpn:06xxxxxxxx " PROBLEM: “Switch name”: CISCO Chassis Environment Check is CRITICAL”" resulted in a return code of 127. Make sure the script or binary you are trying to execute actually exists…
not good… i correct’et the path to the file and puled the power suply again.
SERVICE NOTIFICATION: nagiosadmin;“Switchname”;CISCO Chassis Environment Check;CRITICAL;notify-by-pager;CRITICAL - Fan Power Supply 2 Fan state critical(3) Supply Power Supply 2, WS-CAC-6000W state critical(3)
But no sms.
no error.
no nothing.
I’m looking for a week now but nothing i can find what could be wrong.
I hope that someone can help me with this.
thx in advanced…
greets Palermo