Page 1 of 1

CHECK_NRPE: Receive header underflow - only -1

Posted: Thu May 16, 2019 3:22 am
by admincauce
Hi,

Good morning to all!!!

I have the following problem and I do not know how to solve it. Surely it's silly.

I am monitoring a CentOS server for Nagios. I have correctly configured the nrpe service. When I do a service nrpe status, it launches the following:

● nrpe.service - Nagios Remote Program Executor
   Loaded: loaded (/usr/lib/systemd/system/nrpe.service; disabled; vendor preset: disabled)
   Active: failed (Result: exit-code) since Thu 2019-05-16 08:16:05 WEST; 5min ago
     Docs: http://www.nagios.org/documentation
  Process: 10964 ExecStopPost = / bin / rm -f /var/run/nrpe/nrpe.pid (code = exited, status = 0 / SUCCESS)
  Process: 10962 ExecStart = / usr / sbin / nrpe -c / etc / nagios / nrpe.cfg -f $ NRPE_SSL_OPT (code = exited, status = 2)
 Main PID: 10962 (code = exited, status = 2)

May 16 08:16:05 GESNAG00 systemd [1]: Started Nagios Remote Program Executor.
May 16 08:16:05 GESNAG00 systemd [1]: nrpe.service: main process exited, code = exited, status = 2 / INVALIDARGUMENT
May 16 08:16:05 GESNAG00 systemd [1]: Unit nrpe.service entered failed state.
May 16 08:16:05 GESNAG00 systemd [1]: nrpe.service failed.

But when I launch to verify with the command check_nrpe against any of the checks, it returns me ok:

[root @ GESNAG00] $ / usr / local / nagios / libexec / check_nrpe -H 127.0.0.1 -c check_mem
WARNING - 10.9% (423760 kB) free! | TOTAL = 3880740KB ;;;; USED ​​= 3456980KB; 3104592; 3492666 ;; FREE = 423760KB ;;;; CACHES = 2769752KB ;;;;

What happens is that in Nagios, in the web interface, I get the following information in the chuequeos against this server:

Status Information: CHECK_NRPE: Receive header underflow - only -1 bytes received (4 expected).

What is wrong configured?

Best regards.

Re: CHECK_NRPE: Receive header underflow - only -1

Posted: Thu May 16, 2019 5:02 pm
by npolovenko
@admincauce , Sounds like you may be running multiple nrpe agents on the same server. Please sign in to the nrpe server console, run the following command and show me the output:

Code: Select all

 netstat -anp | grep 5666

Re: CHECK_NRPE: Receive header underflow - only -1

Posted: Fri May 17, 2019 2:51 am
by admincauce
Hi,

Thanks for the reply. This issue was solved.

The problem was in a misconfigured parameter in the nrpe.cfg file that caused it not to correctly raise the nrpe service.

Thank you very much anyway for getting in touch and trying to solve the problem.

regards

:roll: :roll: :roll:

Re: CHECK_NRPE: Receive header underflow - only -1

Posted: Fri May 17, 2019 11:45 am
by benjaminsmith
Hello,
Thanks for the reply. This issue was solved.
Glad that's been resolved! I'll close out this post,but if you have any other issues, please feel free to open a new one.

Thank you for using the Nagios Support Forum.