NRDP

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

NRDP

Post by SDohmen »

I have installed the nagiosxi 1.7 on a centos 6 machine. Later on i added (official) ssl certificates and am currently running the ssl version of the website.

The problem i am facing is that when i try to reach nrdp from a customer it just errors out. With the manual browsing to the nrdp link it works fine btw.

The errors i recieve are the following:

Code: Select all

root@nagios[pts/0]:/etc/nagios3 # /usr/bin/php /usr/local/nrdp/clients/send_nrdp.php  --url=central.**/nrdp --token=** --host=$HOSTNAME$ --service='$SERVICEDESC$' --state=$SERVICESTATE$ --output='$SERVICEOUTPUT$ | $SERVICEPERFDATA$ [$SERVICECHECKCOMMAND$]'
PHP Notice:  Undefined index: host in /usr/local/nrdp/clients/send_nrdp.php on line 368
PHP Warning:  fsockopen(): php_network_getaddresses: getaddrinfo failed: Name or service not known in /usr/local/nrdp/clients/send_nrdp.php on line 368
PHP Warning:  fsockopen(): unable to connect to :443 (php_network_getaddresses: getaddrinfo failed: Name or service not known) in /usr/local/nrdp/clients/send_nrdp.php on line 368

root@nagios[pts/0]:/etc/nagios3 # /usr/bin/php /usr/local/nrdp/clients/send_nrdp.php  --url=https://central.**/nrdp --token=** --host=$HOSTNAME$ --service='$SERVICEDESC$' --state=$SERVICESTATE$ --output='$SERVICEOUTPUT$ | $SERVICEPERFDATA$ [$SERVICECHECKCOMMAND$]'
PHP Warning:  fsockopen(): unable to connect to central.**:80 (Connection timed out) in /usr/local/nrdp/clients/send_nrdp.php on line 368

I tried changing the port to 443 on the line 368 but even then i get no response or anything. Does anyone have a clue how i can resolve this?
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: NRDP

Post by SDohmen »

To add some more info.

I made the website available on port 80 and then NRDP works. Do it set it to SSL again it stops working. I also tried the redirect to see if that would make it go for SSL but also here no luck.
User avatar
nscott
Posts: 1040
Joined: Wed May 11, 2011 8:54 am

Re: NRDP

Post by nscott »

SDohmen,

On your Nagios XI server, can you access

Code: Select all

https://<server address>/nrdp
Nicholas Scott
Former Nagios employee
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: NRDP

Post by SDohmen »

Yes i can.

When i access it at http://<ip>/nrdp i get redirected to the https version even.
mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: NRDP

Post by mguthrie »

fsockopen(): unable to connect to :443 (php_network_getaddresses: getaddrinfo failed: Name or service not known)
Does that remote machine have that host's name defined in the /etc/hosts file, or is it a FQDN?
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: NRDP

Post by SDohmen »

Both to be precise. The hostname is in there and the full fqdn.
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: NRDP

Post by SDohmen »

Anyone else have an idea what could be wrong or how to solve this?
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: NRDP

Post by SDohmen »

I have been testing this whole morning and what i found out is if i dont force ssl with the rewrite, it works, but only as http sending. Even if i use the https link i can clearly read the packet since its not being encrypted. To still force ssl i enabled the sslrequired option in the nrdp.cfg file. But again i am still recieving unencrypted packets fully readable.

What i am wondering now is, if the main central actually is not the problem. It may sound strange but for some reason i am beginning to think that on the sending side it has to be ssl encrypted in some way. I might be wrong here (and prolly are) but does the sending end have to be ssl encrypted aswell?
mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: NRDP

Post by mguthrie »

http://assets.nagios.com/downloads/nagi ... erview.pdf

Try wrapping the hostname macro in double quotes, and if that doesn't work, try single quotes.

root@nagios[pts/0]:/etc/nagios3 # /usr/bin/php /usr/local/nrdp/clients/send_nrdp.php --url=central.**/nrdp --token=** --host=$HOSTNAME$ --service='$SERVICEDESC$' --state=$SERVICESTATE$ --output='$SERVICEOUTPUT$ | $SERVICEPERFDATA$ [$SERVICECHECKCOMMAND$]'
Also, for the URL, you need to specify the full address (https or http)
SDohmen
Posts: 240
Joined: Thu Jun 30, 2011 4:14 am

Re: NRDP

Post by SDohmen »

I tried both of the above but both wont send anything to an SSL connection. As i mentioned before the HTTP part works just fine but there is no encryption. If i force it to a SSL its still not encrypted as it uses the http header. My best guess is that something is wrong on the send nrdp script even though i replaced it several times now.
Locked