NRPE Reports Inforrect Results

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
theangryheretic
Posts: 15
Joined: Fri Feb 24, 2012 4:51 pm

NRPE Reports Inforrect Results

Post by theangryheretic »

I'm running Nagios Core and NRPE on my remote servers that I want to monitor. I looked at the load average in the Nagios web interface, and saw a load average on one of my remote servers as

0.00 0.01 02.3

But when I log into that server and run top, I can see a load average of

2.22 3.90 5.53

Has anyone else had this issue? What did you do to resolve it?

MJ
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: NRPE Reports Inforrect Results

Post by slansing »

Is it possible that the load average had changed between the check iteration and when you opened a session to the server to check? Which plugin are you using to check this through Nagios, can you run it's command through the command line to the server to get a near instant update rather than using the UI to verify?
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: NRPE Reports Inforrect Results

Post by lmiltchev »

This is strange. Can you run the check locally, on the remote server, and then from nagios? For example:

On the remote server:

Code: Select all

./check_load -w 15,10,5 -c 30,20,10
On the nagios server:

Code: Select all

./check_nrpe -H <client_IP> -t 30 -c check_load -a '-w 15,10,5 -c 30,20,10'
Post the output of both commands.
Be sure to check out our Knowledgebase for helpful articles and solutions!
theangryheretic
Posts: 15
Joined: Fri Feb 24, 2012 4:51 pm

Re: NRPE Reports Inforrect Results

Post by theangryheretic »

This server I am checking is running a job that takes a few hours to complete, and the time between my checking the web page and command line is maybe 2 or 3 minutes. I'm using the check_load plugin that comes standard with a nagios install.
MJ
slansing wrote:Is it possible that the load average had changed between the check iteration and when you opened a session to the server to check? Which plugin are you using to check this through Nagios, can you run it's command through the command line to the server to get a near instant update rather than using the UI to verify?
Last edited by theangryheretic on Mon May 06, 2013 11:43 am, edited 1 time in total.
theangryheretic
Posts: 15
Joined: Fri Feb 24, 2012 4:51 pm

Re: NRPE Reports Inforrect Results

Post by theangryheretic »

When I run the command locally on the "remote" server, I get these results.

WARNING - load average: 2.46, 5.66, 6.73|load1=2.460;15.000;30.000;0; load5=5.660;10.000;20.000;0; load15=6.730;5.000;10.000;0;

When I run the command on the nagios server, to check the remote server, it tells me

CHECK_NRPE: Received 0 bytes from daemon. Check the remote server logs for error messages.

When I check the logs, I get this,

May 6 12:27:43 kaos nrpe[24996]: Error: Request contained command arguments, but argument option is not enabled!
May 6 12:27:43 kaos nrpe[24996]: Client request was invalid, bailing out...


In the NRPE config file, I have dont_blame_nrpe set to 0, since the documentation I have looked at tells me it is a security risk to change it to 1, and allow arguments to be passed.

lmiltchev wrote:This is strange. Can you run the check locally, on the remote server, and then from nagios? For example:

On the remote server:

Code: Select all

./check_load -w 15,10,5 -c 30,20,10
On the nagios server:

Code: Select all

./check_nrpe -H <client_IP> -t 30 -c check_load -a '-w 15,10,5 -c 30,20,10'
Post the output of both commands.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: NRPE Reports Inforrect Results

Post by abrist »

What is the command definition in the remote host's nrpe.cfg file for the check?

You may want to look over the following document as it covers the most common nrpe errors:
http://library.nagios.com/library/produ ... -solutions
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.
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: NRPE Reports Inforrect Results

Post by lmiltchev »

You certainly don't have to pass arguments. This was just an example. I had the following check defined on the remote box:

Code: Select all

command[check_load]=/usr/local/nagios/libexec/check_load $ARG1$ 

That's why I need it to pass arguments:

Code: Select all

./check_nrpe -H <client_IP> -t 30 -c check_load -a '-w 15,10,5 -c 30,20,10'
But if you had:

Code: Select all

command[check_load]=/usr/local/nagios/libexec/check_load -w 15,10,5 -c 30,20,10
on the remote box, then you could've just ran:

Code: Select all

./check_nrpe -H <client_IP> -t 30 -c check_load
I just wanted you to run both checks (with no big interval between checks), and compare the output.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked