Page 1 of 1

Problem with Check NRPE from XI Core

Posted: Tue Dec 02, 2014 12:15 pm
by rogersochieng
I want to get some performance counters in Windows so I did a test check in CLI

[root@centosnagiois static]# /usr/local/nagios/libexec/check_nrpe -H AFDBLYNCDB01.afdb.local -p 5666 -c CheckCounter -a "\\MSSQL\$LYNCARC:Resource Pool Stats(*)\\CPU usage %" ShowAll MaxWarn=10 MaxCrit=20

OK: \MSSQL$LYNCARC:Resource Pool Stats(*)\CPU usage %: 0|'\MSSQL$LYNCARC:Resource Pool Stats(*)\CPU usage %'=0;10;20

But when I create the same in Nagios XI Core I get below error. Please advise
COMMAND: /usr/local/nagios/libexec/check_nrpe -H AFDBLYNCDB01.afdb.local -p 5666 -c CheckCounter -a "\\MSSQL\\\$LYNCARC:Resource Pool Stats\(\*\)\\CPU usage %" ShowAll MaxWarn=10 MaxCrit=20
OUTPUT: CRIT: Counter not found: \MSSQL\$LYNCARC:Resource Pool Stats\(\*\)\CPU usage %: -1073738824: The specified object was not found on the computer.

Re: Problem with Check NRPE from XI Core

Posted: Tue Dec 02, 2014 12:35 pm
by tmcdonald
Are you using the Test Check Command from the CCM? If so, it may not always work because it escapes certain characters, as can be seen below:

Code: Select all

... Resource Pool Stats\(\*\) ...
Try saving the command and click Apply Config, then let the check run normally and see the output.

Re: Problem with Check NRPE from XI Core

Posted: Tue Dec 02, 2014 2:40 pm
by rogersochieng
Indeed I was testing with CCM Test Check Command.

I went ahead and saved below argument
"\\MSSQL\$LYNCARC:Resource Pool Stats(*)\\CPU usage %" ShowAll MaxWarn=10 MaxCrit=20


When I look in view I see that that it has escaped ( and * character below and failed

CRIT: Counter not found: \MSSQL\$LYNCARC:Resource Pool Stats\(\*\)\CPU usage %$: -1073738824: The specified object was not found on the computer.

Re: Problem with Check NRPE from XI Core

Posted: Tue Dec 02, 2014 3:54 pm
by tmcdonald
Please see my answer in this thread: http://support.nagios.com/forum/viewtop ... 13#p118913

Also as a general rule we ask to keep all related responses in one thread so we can deal with them in one place instead of having possibly double the responses to a single issue.