Page 1 of 2
Connection Issues between NRPE V.20 and NRPE 2.16 RC2
Posted: Wed Apr 13, 2016 2:09 am
by mdusanapudi
Hi ,
I installed nrpe v2.16 RC2 on my nagios server , And after the upgrade All the HP UX agents running nrpe V2.0 were not able to connect to the nagios server Running 2.16RC2.
I check the nrpe agent from command line as well from nagios server as well as the client.
Below are my observation:
1.when try to connect NRPE V2.0 agent on HP UX from nagios server running NRPE v.216RC2 nothing happens and have to kill the command forcibly.
2. When tried to connect to NRPE V2.16RC2 on nagios server from NRPE V2.0 HP UX box getting the below error
CHECK_NRPE: Error receiving data from daemon.
Rest of the machines running NRPE V2.15 were able to connect to the nagios server without any issues ,only these HP UX boxes running NRPE V2.0 not able to connect.
not sure if its a bug.
Please let me know if need to to change anything with respect to configs.
Re: Connection Issues between NRPE V.20 and NRPE 2.16 RC2
Posted: Wed Apr 13, 2016 9:54 am
by lmiltchev
According to our developers, this is not a bug. NRPE v2.0 is really old... Try compiling at least NRPE 2.15 on the HP-UX boxes. Let us know if this helped.
Re: Connection Issues between NRPE V.20 and NRPE 2.16 RC2
Posted: Wed Apr 13, 2016 10:35 am
by mdusanapudi
Can you please let me know if there is any documentation to do that.I am finding it really tough to install nrpe agent on HP UX.
Re: Connection Issues between NRPE V.20 and NRPE 2.16 RC2
Posted: Wed Apr 13, 2016 1:21 pm
by lmiltchev
You are correct - there is not much info about compiling NRPE on HP-UX. We don't have any "specific" instructions for HP-UX, and I am not finding anything useful online. Here is the official Nagios NRPE documentation:
https://assets.nagios.com/downloads/nag ... e/NRPE.pdf
but you probably have already seen this document.
What are the errors that you are getting when you try to compile NRPE on HP-UX? Maybe our developers can help you out with finding a workable solution.
BTW, have you tried stopping nrpe daemon on HP UX, and starting it with the "-n" flag? Does your check work with SSL disabled?
Re: Connection Issues between NRPE V.20 and NRPE 2.16 RC2
Posted: Wed Apr 13, 2016 2:07 pm
by mdusanapudi
You are right ....I tried to compile without ssl by using --disable-ssl even then it doesn't work.
But the version 2.0 is installed using pre compiled binaries may that's why its working on this machine.
I have lot of questions around this nrpe v2.16RC2
I tried installing it on redhat 5.11 getting some eerors during make.Tested on 4 machines still getting the same error.
below is the error I am getting...not sure if its a bug.
# make
cd ./src/; make ; cd ..
make[1]: Entering directory `/tmp/nrpe-nrpe-2-16-RC2/src'
gcc -g -O2 -I/usr/include/openssl -I/usr/include -DHAVE_CONFIG_H -I ../includeI ./../include -o nrpe ./nrpe.c ./utils.c ./acl.c -L/usr/lib64 -lssl -lcryptolnsl -lwrap
./nrpe.c: In function ‘main’:
./nrpe.c:332: warning: assignment makes pointer from integer without a cast
./nrpe.c:334: warning: assignment makes pointer from integer without a cast
./nrpe.c:336: warning: passing argument 1 of ‘SSL_CTX_new’ discards qualifiersrom pointer target type
/tmp/ccsJILKx.o: In function `main':
/tmp/nrpe-nrpe-2-16-RC2/src/./nrpe.c:334: undefined reference to `TLSv1_2_serv_method'
/tmp/nrpe-nrpe-2-16-RC2/src/./nrpe.c:332: undefined reference to `TLSv1_1_serv_method'
collect2: ld returned 1 exit status
make[1]: *** [nrpe] Error 1
make[1]: Leaving directory `/tmp/nrpe-nrpe-2-16-RC2/src'
*** Compile finished ***
Re: Connection Issues between NRPE V.20 and NRPE 2.16 RC2
Posted: Wed Apr 13, 2016 2:27 pm
by jfrickson
mdusanapudi wrote:You are right ....I tried to compile without ssl by using --disable-ssl even then it doesn't work.
But the version 2.0 is installed using pre compiled binaries may that's why its working on this machine.
Try it with SSL compiled in, but run the daemon with it turned off:
Code: Select all
/usr/local/nagios/bin/nrpe -n -c /usr/local/nagios/etc/nrpe.cfg
and see how that works.
mdusanapudi wrote:I tried installing it on redhat 5.11 getting some eerors during make.Tested on 4 machines still getting the same error.
below is the error I am getting...not sure if its a bug.
# make
cd ./src/; make ; cd ..
make[1]: Entering directory `/tmp/nrpe-nrpe-2-16-RC2/src'
gcc -g -O2 -I/usr/include/openssl -I/usr/include -DHAVE_CONFIG_H -I ../includeI ./../include -o nrpe ./nrpe.c ./utils.c ./acl.c -L/usr/lib64 -lssl -lcryptolnsl -lwrap
./nrpe.c: In function ‘main’:
./nrpe.c:332: warning: assignment makes pointer from integer without a cast
./nrpe.c:334: warning: assignment makes pointer from integer without a cast
./nrpe.c:336: warning: passing argument 1 of ‘SSL_CTX_new’ discards qualifiersrom pointer target type
/tmp/ccsJILKx.o: In function `main':
/tmp/nrpe-nrpe-2-16-RC2/src/./nrpe.c:334: undefined reference to `TLSv1_2_serv_method'
/tmp/nrpe-nrpe-2-16-RC2/src/./nrpe.c:332: undefined reference to `TLSv1_1_serv_method'
collect2: ld returned 1 exit status
make[1]: *** [nrpe] Error 1
make[1]: Leaving directory `/tmp/nrpe-nrpe-2-16-RC2/src'
*** Compile finished ***
That shouldn't happen

It looks like you have an older version of openssl (0.9.6?) but it should figure that out and compile cleanly. I'll look into it.
Re: Connection Issues between NRPE V.20 and NRPE 2.16 RC2
Posted: Thu Apr 14, 2016 5:20 am
by mdusanapudi
I tried compiling without disabling SSL and still getting the same error during make.
steps performed
make clean
./configure
attached the text file containing the output of ./configure
make all
nrpe-nrpe-2-16-RC2]# make all
cd ./src/; make ; cd ..
make[1]: Entering directory `/tmp/nrpe-nrpe-2-16-RC2/src'
gcc -g -O2 -I/usr/include/openssl -I/usr/include -DHAVE_CONFIG_H -I ../include -I ./../include -o nrpe ./nrpe.c ./utils.c ./acl.c -L/usr/lib64 -lssl -lcrypto -lnsl -lwrap
./nrpe.c: In function ‘main’:
./nrpe.c:332: warning: assignment makes pointer from integer without a cast
./nrpe.c:334: warning: assignment makes pointer from integer without a cast
./nrpe.c:336: warning: passing argument 1 of ‘SSL_CTX_new’ discards qualifiers from pointer target type
/tmp/ccoj2SFE.o: In function `main':
/tmp/nrpe-nrpe-2-16-RC2/src/./nrpe.c:334: undefined reference to `TLSv1_2_server_method'
/tmp/nrpe-nrpe-2-16-RC2/src/./nrpe.c:332: undefined reference to `TLSv1_1_server_method'
collect2: ld returned 1 exit status
make[1]: *** [nrpe] Error 1
make[1]: Leaving directory `/tmp/nrpe-nrpe-2-16-RC2/src'
*** Compile finished ***
If the NRPE daemon and client compiled without any errors, you
can continue with the installation or upgrade process.
Read the PDF documentation (NRPE.pdf) for information on the next
steps you should take to complete the installation or upgrade.
Re: Connection Issues between NRPE V.20 and NRPE 2.16 RC2
Posted: Thu Apr 14, 2016 9:11 am
by jfrickson
mdusanapudi wrote:I tried compiling without disabling SSL and still getting the same error during make.
./nrpe.c:332: warning: assignment makes pointer from integer without a cast
./nrpe.c:334: warning: assignment makes pointer from integer without a cast
./nrpe.c:336: warning: passing argument 1 of ‘SSL_CTX_new’ discards qualifiers from pointer target type
/tmp/nrpe-nrpe-2-16-RC2/src/./nrpe.c:334: undefined reference to `TLSv1_2_server_method'
/tmp/nrpe-nrpe-2-16-RC2/src/./nrpe.c:332: undefined reference to `TLSv1_1_server_method'
Starting at line 331 in src/nrpe.c and at line 485 in src/check_nrpe.c, you should have these lines:
Code: Select all
if (sslprm.ssl_min_ver == TLSv1_1)
meth = TLSv1_1_server_method();
if (sslprm.ssl_min_ver == TLSv1_2)
meth = TLSv1_2_server_method();
Comment those out, and it should compile.
Code: Select all
/*
if (sslprm.ssl_min_ver == TLSv1_1)
meth = TLSv1_1_server_method();
if (sslprm.ssl_min_ver == TLSv1_2)
meth = TLSv1_2_server_method();
*/
Re: Connection Issues between NRPE V.20 and NRPE 2.16 RC2
Posted: Thu Apr 14, 2016 9:57 am
by mdusanapudi
Output after changing nrpe.c and check_nrpe.c
[root@dalpoclxnaxi01 nrpe-nrpe-2-16-RC2]# make all
cd ./src/; make ; cd ..
make[1]: Entering directory `/tmp/nrpe-nrpe-2-16-RC2/src'
gcc -g -O2 -I/usr/include/openssl -I/usr/include -DHAVE_CONFIG_H -I ../include -I ./../include -o nrpe ./nrpe.c ./utils.c ./acl.c -L/usr/lib64 -lssl -lcrypto -lnsl -lwrap
./nrpe.c: In function ‘main’:
./nrpe.c:337: warning: passing argument 1 of ‘SSL_CTX_new’ discards qualifiers from pointer target type
gcc -g -O2 -I/usr/include/openssl -I/usr/include -DHAVE_CONFIG_H -I ../include -I ./../include -o check_nrpe ./check_nrpe.c ./utils.c -L/usr/lib64 -lssl -lcrypto -lnsl
./check_nrpe.c: In function ‘setup_ssl’:
./check_nrpe.c:492: warning: passing argument 1 of ‘SSL_CTX_new’ discards qualifiers from pointer target type
make[1]: Leaving directory `/tmp/nrpe-nrpe-2-16-RC2/src'
*** Compile finished ***
If the NRPE daemon and client compiled without any errors, you
can continue with the installation or upgrade process.
Read the PDF documentation (NRPE.pdf) for information on the next
steps you should take to complete the installation or upgrade.
Re: Connection Issues between NRPE V.20 and NRPE 2.16 RC2
Posted: Thu Apr 14, 2016 10:05 am
by jfrickson
Ok, it compiled. Does it work?