No output returned from plugin
No output returned from plugin
I set up a check and when I run it from the command line I get data returned, but when I run it in Nagios I get (No output returned from plugin).
Here's the command line I got from Nagios when I test the config:
/usr/local/nagios/libexec/check_casper script.js /usr/local/nagios/libexec/admin_ui-stage.js
This is what is returned from the command line:
PASS 3 tests executed in 2.398s, 3 passed, 0 failed, 0 dubious, 0 skipped.
And the exit code:
echo $?
0
Any idea's why this is happening or how I should go about troubleshooting?
Here's the command line I got from Nagios when I test the config:
/usr/local/nagios/libexec/check_casper script.js /usr/local/nagios/libexec/admin_ui-stage.js
This is what is returned from the command line:
PASS 3 tests executed in 2.398s, 3 passed, 0 failed, 0 dubious, 0 skipped.
And the exit code:
echo $?
0
Any idea's why this is happening or how I should go about troubleshooting?
Re: No output returned from plugin
Can you run the check as nagios user?
Code: Select all
su nagios -c '<full path to your command>'Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: No output returned from plugin
su nagios -c /usr/local/nagios/libexec/check_casper script.js /usr/local/nagios/libexec/admin_ui-stage.js
PASS 3 tests executed in 7.342s, 3 passed, 0 failed, 0 dubious, 0 skipped.
same thing.
PASS 3 tests executed in 7.342s, 3 passed, 0 failed, 0 dubious, 0 skipped.
same thing.
Re: No output returned from plugin
Can you show us the command and service definitions? How did you set up this check? Did you follow this document?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: No output returned from plugin
define command {
command_name check_casper3
command_line $USER1$/check_casper $ARG1$ $ARG2$
}
define service {
host_name www-xxx.xxx.com
service_description HTTP - IAM User Mgt UI VIP Login - DIT
use generic-service-active
check_command check_casper3!script.js!/usr/local/nagios/libexec/admin_ui-stage.js !!!!!!
register 1
}
Not sure where those extra bangs came in, something added from the GUI i guess.
command_name check_casper3
command_line $USER1$/check_casper $ARG1$ $ARG2$
}
define service {
host_name www-xxx.xxx.com
service_description HTTP - IAM User Mgt UI VIP Login - DIT
use generic-service-active
check_command check_casper3!script.js!/usr/local/nagios/libexec/admin_ui-stage.js !!!!!!
register 1
}
Not sure where those extra bangs came in, something added from the GUI i guess.
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: No output returned from plugin
The only thing I can spot is in your service definition is a space between admin_ui-stage.js and !.
check_command check_casper3!script.js!/usr/local/nagios/libexec/admin_ui-stage.jsspace!!!!!!
It shouldn't make a difference but I've see stranger things happen.
check_command check_casper3!script.js!/usr/local/nagios/libexec/admin_ui-stage.jsspace!!!!!!
It shouldn't make a difference but I've see stranger things happen.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: No output returned from plugin
I acutally had to remove a little text from there, but besides what I removed for privacy reasons, the check is basically the same.
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: No output returned from plugin
If $ARG2$ is populated with spaces then your command definintion will need quotes to enclose the argument.
For example:
See how that goes.
Code: Select all
\"$ARG2$\"Code: Select all
define command {
command_name check_casper3
command_line $USER1$/check_casper $ARG1$ \"$ARG2$\"
} As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: No output returned from plugin
Same thing 
Re: No output returned from plugin
Is "check_casper" a custom plugin? Can you provide us with a download link, so that we can test it in house?
Be sure to check out our Knowledgebase for helpful articles and solutions!