I've got a new plugin I'm trying to get running. I've done quite a few that ran through NRPE on another machine. I'm running this one on the local Nagios server, first one I've done custom on the local server, should be even easier?
The code just basically runs a sql query, getting a scalar value back and writing a message, exiting with 0,1,2 (etc. ).
Here's the output from the command line.
[nagios@nagiosxi ~]$ mono /usr/local/nagios/libexec/GenericSqlPlugin/GenericSqlPlugin.exe /usr/local/nagios/etc/Config.xml
22 orders in GccOrders
Here are the perms
[nagios@nagiosxi ~]$ ls -la /usr/local/nagios/libexec/GenericSqlPlugin/
-rwsr-xr-- 1 root nagios 7168 May 16 09:17 GenericSqlPlugin.exe
-rwsr-xr-- 1 root nagios 209 May 16 09:17 GenericSqlPlugin.exe.config
Here's what Nagios says during test.
Testing check from command line...
COMMAND: mono /usr/local/nagios/libexec/GenericSqlPlugin/GenericSqlPlugin.exe /usr/local/nagios/etc/Config.xml
OUTPUT:
I can't see why the test wouldn't work.
Any help is welcome.
Cam
No output in NagiosXI from command
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: No output in NagiosXI from command
"Test Check Command" button in CCM doesn't always work. Best test is to Apply Configuration and then go and search for the service under Home > Details > Service Detail. Click on the service and then "Schedule a forced immediate check"
As for file permissions, I would try:
As for file permissions, I would try:
Code: Select all
chown -R nagios:nagcmd /usr/local/nagios/libexec/GenericSqlPluginAs of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: No output in NagiosXI from command
Actually it still wasn't running correctly, but you are right, I got a better error message. Thanks!
Note to others as absent minded as I:
Make sure you have your command in the PATH!!!
Note to others as absent minded as I:
Make sure you have your command in the PATH!!!
Re: No output in NagiosXI from command
Nice! Can we assume that this issue is indeed resolved?
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.