Page 1 of 1

Passive Checks Performance Graphing

Posted: Wed Oct 26, 2016 3:23 pm
by ciaranrh
Hello,

I have nsclient++ (version 0.5.x) running on a number of windows servers in my environment, all of which report to my NagiosXI server via passive checks. I've noticed active checks will easily create performance data but for whatever reason I can't seem to get performance graphs for data received from passive checks.

I've worked through this link: https://support.nagios.com/kb/article.php?id=9 which revealed no issue - this was expected though since active checks still work, it's likely something with how data is being submitted to Nagios from nsclient.

Here's an example of the command being run on nsclient:

Code: Select all

check_cpu "warn=load > 90" "crit=load > 95" show-all
L        cli OK: OK: 5m: 4%, 1m: 3%, 5s: 1%
L        cli  Performance data: 'total 5m'=4%;90;95 'total 1m'=3%;90;95 'total 5s'=1%;90;95
Here's what NagiosXI receives:

Code: Select all

Oct 26 16:08:54 nagiosxi nsca[12842]: SERVICE CHECK -> Host Name: 'STOR-01B', Service Description: 'CPU Usage', Return Code: '0', Output: 'OK: 5m: 4%, 1m: 3%, 5s: 1%|'total 5m'=4%;90;95 'total 1m'=3%;90;95 'total 5s'=1%;90;95'
Oct 26 16:08:54 nagiosxi nagios: EXTERNAL COMMAND: PROCESS_SERVICE_CHECK_RESULT;STOR-01B;CPU Usage;0;OK: 5m: 4%, 1m: 3%, 5s: 1%|'total 5m'=4%;90;95 'total 1m'=3%;90;95 'total 5s'=1%;90;95
Oct 26 16:08:54 nagiosxi nagios: PASSIVE SERVICE CHECK: STOR-01B;CPU Usage;0;OK: 5m: 4%, 1m: 3%, 5s: 1%
I'm not sure how to read the performance data though, I know the nsclient documentation states that the performance data can be manipulated and I'm thinking that's exactly what I need to do to get this working I'm just unsure on the formatting of it. Does anyone have some experience with this?

Any replies are appreciated :)

Re: Passive Checks Performance Graphing

Posted: Wed Oct 26, 2016 3:55 pm
by dwhitfield
Your passive check results will need to include performance data as per the following doc:

https://nagios-plugins.org/doc/guidelines.html#AEN200

Re: Passive Checks Performance Graphing

Posted: Wed Oct 26, 2016 4:27 pm
by ciaranrh
Thanks,

Wouldn't what nsclient is outputting meet those requirements though, if we look at the 5m total below:

Code: Select all

Performance data: 'total 5m'=4%;90;95 'total 1m'=3%;90;95 'total 5s'=1%;90;95

'total 5m'=4%;90;95
That would seem to correspond with the guidelines:
'label'=value[UOM];[warn];[crit];[min];[max]
Label would be 'total 5m'
Value would be '4%'
Warn and Crit 90 and 95 respectively.

This would then be repeated for a separate bar for 1m total and 5s total in that graph. Do I have this mistaken?

Re: Passive Checks Performance Graphing

Posted: Wed Oct 26, 2016 4:55 pm
by dwhitfield
My apologies, I missed the % the first time through. Are you using anything like PNP4Nagios, or just the stuff mentioned in https://support.nagios.com/kb/article.php?id=9 ?

Could you PM me your profile? Admin -> System Profile (Under System Config) -> Download Profile

If the profile is too big to attach, just send your objects.cache.

UPDATE: objects.cache on shared drive

Re: Passive Checks Performance Graphing

Posted: Thu Oct 27, 2016 12:31 pm
by ciaranrh
Hello,

I sent the requested data in a PM. Let me know if you got it.

Cheers!

Re: Passive Checks Performance Graphing

Posted: Thu Oct 27, 2016 2:57 pm
by dwhitfield
I've been taking a look at the objects.cache file. It's 376712 lines long, so it is going to take me a while.

To help me narrow down my search, could you clarify how you are graphing? You are just using the built in graphing, correct? Also, what version of XI are you using?

Re: Passive Checks Performance Graphing

Posted: Fri Oct 28, 2016 4:29 pm
by ciaranrh
Hey,

We are just using built in graphing, we're running Nagios version 5.2.9. If it helps to narrow down your search the one host/service check I'm trying to graph from is named 'STOR-01A'.

Cheers!

Re: Passive Checks Performance Graphing

Posted: Mon Oct 31, 2016 11:11 am
by dwhitfield
What OS are you running? There appear to be some issues with CentOS/RHEL 6 (and presumably 7, though I don't know) when you have a mixed 32/64-bit environment. Those issues do not appear in RHEL 5.

Also, let's run through https://support.nagios.com/kb/article.php?id=511. That article talks about bandwidth explicitly, but MRTG handles different graphing components, including passive checks (https://assets.nagios.com/downloads/nag ... raphs.html), so we should make sure it is working properly.

Re: Passive Checks Performance Graphing

Posted: Wed Nov 09, 2016 6:17 pm
by ciaranrh
Hey, this can be closed.

Seems there was a general graphing issue regardless of active/passive check. This was resolved and the passive checks I have are now being graphed. Lesson here being not to become too fixated on one single issue :)

Thanks for your time and help.

Re: Passive Checks Performance Graphing

Posted: Thu Nov 10, 2016 12:24 pm
by tmcdonald
Glad to hear it! I'll be closing this thread now, but feel free to open another if you need anything in the future!