I'm sorry if this is a stupid question, but I've looked in the docs to no avail.
I'm trying to extract data from a Nagios 4.0.8 installation with the JSON CGIs. I've been experimenting with the built-in Query Generator and I'm successfully able to parse the JSON data from my external application.
The problem I'm running into is the "status" field when doing a host or service query. I'm seeing status codes like this:
"data": {
"host": {
"name": "myhost.com",
"plugin_output": "CRITICAL - Host Unreachable (10.0.1.113)",
"long_plugin_output": "",
"perf_data": "",
"status": 4,
And on some services, I'm seeing:
"status": 16,
I've looked in the Nagios docs and I'm only seeing four plugin return codes: 0, 1, 2, and 3.
Where is the JSON status cgi pulling these status numbers from and where can I find a list?
JSON CGIs "status"
-
- -fno-stack-protector
- Posts: 4366
- Joined: Mon Nov 19, 2012 12:10 pm
Re: JSON CGIs "status"
Well thats an interesting find! Could I ask that you post this as an issue on github @ https://github.com/NagiosEnterprises/nagioscore This way the core developers will be made aware of it right away. So far I don't see any commits matching this issue, so probably something brand new they are unaware of.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.