nagios eventhandler
Posted: Thu Dec 13, 2012 2:29 pm
my case statement in shell looks like below
case "$1" in
OK)
case "$2" in
SOFT)
case "$3" in
1)
printf testing | /usr/lib64/nagios/plugins/eventhandlers/sms.py --topic=arn:aws:sns:us-east-1:12334323:xxxx-test --sub="testing"
nagios stripping printf "testing" and running python sms.py --topic=arn:aws:sns:us-east-1:12334323:xxxx-test --sub="test" and hanging with no result. If I run printf testing | /usr/lib64/nagios/plugins/eventhandlers/sms.py --topic=arn:aws:sns:us-east-1:12334323:xxxx-test --sub="testing" command manually it works fine. I want nagios to run whole command instead of stripping "printf testing |". Thanks for help in advance
case "$1" in
OK)
case "$2" in
SOFT)
case "$3" in
1)
printf testing | /usr/lib64/nagios/plugins/eventhandlers/sms.py --topic=arn:aws:sns:us-east-1:12334323:xxxx-test --sub="testing"
nagios stripping printf "testing" and running python sms.py --topic=arn:aws:sns:us-east-1:12334323:xxxx-test --sub="test" and hanging with no result. If I run printf testing | /usr/lib64/nagios/plugins/eventhandlers/sms.py --topic=arn:aws:sns:us-east-1:12334323:xxxx-test --sub="testing" command manually it works fine. I want nagios to run whole command instead of stripping "printf testing |". Thanks for help in advance