NRPE payload return

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
SteveBeauchemin
Posts: 524
Joined: Mon Oct 14, 2013 7:19 pm

NRPE payload return

Post by SteveBeauchemin »

I have a need to get many lines of data returned from a service test using check_nrpe.
At this time, the return is being truncated to 8189 bytes.
This is my returned data on my Nagios XI host

Code: Select all

/usr/local/nagios/libexec/check_nrpe -H [remote-host] -c roll-logs -a "oraarchlog pr1" > /tmp/x.x
wc /tmp/x.x
 179  796 8189 /tmp/x.x
This is the file on the remote host that I need to have in the Nagios Status Information display. This is the expected return data.

Code: Select all

wc oracle-archive.log
445 1812 18899 oracle-archive.log
The data above needs to be seen by the Data Center operators.

The version of nrpe on both hosts is 3.2.1
Remote host is HP-UX. I compiled and deployed the nrpe.

Code: Select all

/usr/local/nagios/libexec/check_nrpe -H [remote-host]
NRPE v3.2.1
The Nagios XI host. Also compiled by me.

Code: Select all

/usr/local/nagios/libexec/check_nrpe -V
NRPE Plugin for Nagios
Version: 3.2.1
Are there some code edits I need to make to get a 64K packet size to work?

Please advise...

Thanks

Steve B
XI 5.7.3 / Core 4.4.6 / NagVis 1.9.8 / LiveStatus 1.5.0p11 / RRDCached 1.7.0 / Redis 3.2.8 /
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
syang

Re: NRPE payload return

Post by syang »

Hello Steve,

Please take a look at this link explaining how to increase NRPE payload: https://support.nagios.com/kb/article.php?id=518
Hope this helps!

See
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: NRPE payload return

Post by scottwilkerson »

What if you add a larger payload length to the check_nrpe command -P 32768

Code: Select all

/usr/local/nagios/libexec/check_nrpe -H [remote-host] -P 32768 -c roll-logs -a "oraarchlog pr1" > /tmp/x.x
wc /tmp/x.x
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
SteveBeauchemin
Posts: 524
Joined: Mon Oct 14, 2013 7:19 pm

Re: NRPE payload return

Post by SteveBeauchemin »

From what I can tell, the -P [buffer-size] command only works if you use the -2 to force it into Version 2 mode.

Code: Select all

./check_nrpe -H dbusrpr1 -P 32768 -c roll-logs -a "oraarchlog pr1"
Error: if a fixed payload size is specified, '-2' must also be specified

Incorrect command line arguments supplied

Code: Select all

./check_nrpe -H dbusrpr1 -2 -P 32768 -c roll-logs -a "oraarchlog pr1"
CHECK_NRPE: Receive header underflow - only 0 bytes received (4 expected).
Steve B
XI 5.7.3 / Core 4.4.6 / NagVis 1.9.8 / LiveStatus 1.5.0p11 / RRDCached 1.7.0 / Redis 3.2.8 /
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
SteveBeauchemin
Posts: 524
Joined: Mon Oct 14, 2013 7:19 pm

Re: NRPE payload return

Post by SteveBeauchemin »

syang

I looked at that KB article, and others. I always research before posting. Posting is my last resource... my final step if I cannot fix something.

I am not using NSClient++ for this test.

Both sides of the communication channel are nrpe that I compiled. Version 3.2.1

From what I understand, the packet size is supposed to be able to get up to 64K. I need less than 20K. I am getting 8K.

The -P parameter only works for Version 2 communication to NSClient++

I think the solution I need requires a code edit to fix the problem. I think this is a bug. I read that 64K packet size now works. Make it so. Please.

In the nrpe changelog for release 3.0.0 - 2016-08-01
  • Added support for version 3 variable sized packets up to 64KB. nrpe will accept either version from check_nrpe. check_nrpe will try to send a version 3 packet first, and fall back to version 2. check_nrpe can be forced to only send version 2 packets if the switch -2 is used.

Steve B
XI 5.7.3 / Core 4.4.6 / NagVis 1.9.8 / LiveStatus 1.5.0p11 / RRDCached 1.7.0 / Redis 3.2.8 /
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
npolovenko
Support Tech
Posts: 3457
Joined: Mon May 15, 2017 5:00 pm

Re: NRPE payload return

Post by npolovenko »

@SteveBeauchemin, Would you be able to open a new issue on the Github page?
https://github.com/NagiosEnterprises/nrpe/issues/new
That way you can continue troubleshooting this problem directly with our Dev team.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
SteveBeauchemin
Posts: 524
Joined: Mon Oct 14, 2013 7:19 pm

Re: NRPE payload return

Post by SteveBeauchemin »

XI 5.7.3 / Core 4.4.6 / NagVis 1.9.8 / LiveStatus 1.5.0p11 / RRDCached 1.7.0 / Redis 3.2.8 /
SNMPTT / Gearman 0.33-7 / Mod_Gearman 3.0.7 / NLS 2.0.8 / NNA 2.3.1 /
NSClient 0.5.0 / NRPE Solaris 3.2.1 Linux 3.2.1 HPUX 3.2.1
npolovenko
Support Tech
Posts: 3457
Joined: Mon May 15, 2017 5:00 pm

Re: NRPE payload return

Post by npolovenko »

@SteveBeauchemin, Great, you can also reference this thread in the description of the issue on GitHub. I will be closing this forum thread.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Locked