CentOS 5.5 client install problem

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
mdzx111
Posts: 39
Joined: Tue Apr 17, 2012 2:27 pm

CentOS 5.5 client install problem

Post by mdzx111 »

Hello,

So I followed the instructions to install the CentOS monitoring agent on my machine. I've done this several times now successfully. When I ran the install this time, it appeared to install just fine with no errors. However when I try to connect to it using NagiosXI, I'm getting a successful ping but everything else says connection refused or timed out.

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

Re: CentOS 5.5 client install problem

Post by scottwilkerson »

This may have not not installed successfully

to test from the Nagios XI machine run

Code: Select all

cd /usr/local/nagios/libexec
./check_nrpe -H <client_machine_IP>
you should see

Code: Select all

NRPE v2.12
If not, back on the client run

Code: Select all

yum -y install autoconf gcc glibc libmcrypt-devel make openssl-devel  perl-Net-SMTP-TLS sudo sysstat xinetd
If this goes without error, re-run the agent installer
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
mdzx111
Posts: 39
Joined: Tue Apr 17, 2012 2:27 pm

Re: CentOS 5.5 client install problem

Post by mdzx111 »

Well Scott, I got to give you an A for effort but no luck. I wasnt able to connect from the NagiosXI box to the client machine 192.168.1.41 running:

cd /usr/local/nagios/libexec
./check_nrpe -H 192.168.1.41

I got the same error as within NagiosXI which is connection refused or timed out. Keep in mind I can ping this machine within NagiosXI.

So I ran:

yum -y install autoconf gcc glibc libmcrypt-devel make openssl-devel perl-Net-SMTP-TLS sudo sysstat xinetd

and it ran fine without any errors, updated whatever it needed to and was happy.

Then I re-ran the install and it ran without errors, but in the end I get the same results.....

Connection refused or timed out.

Please also keep in mind you've helped me on CentOS earlier and because of that I've been able to monitor several other machines. So I somewhat know what I'm doing.

Thank you again for all your hard work. Now what's next?
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: CentOS 5.5 client install problem

Post by scottwilkerson »

Ok, on the client lets run

Code: Select all

cd /usr/local/nagios/libexec
./check_nrpe -H localhost
You should get

Code: Select all

CHECK_NRPE: Error - Could not complete SSL handshake.
If so, it is listening, which is good. Then from the XI server site we need to see if we can reach the client

Code: Select all

ping 192.168.1.41
If that goes ok, lets try to telnet to it

Code: Select all

telnet 192.168.1.41 5667
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
mdzx111
Posts: 39
Joined: Tue Apr 17, 2012 2:27 pm

Re: CentOS 5.5 client install problem

Post by mdzx111 »

I have always been able to ping from the XI box to 192.168.1.41 in SSH and in XI.

When I run:
cd /usr/local/nagios/libexec
./check_nrpe -H localhost

I get:


[root@web2 linux-nrpe-agent]# cd /usr/local/nagios/libexec
[root@web2 libexec]# ./check_nrpe -H localhost
CHECK_NRPE: Socket timeout after 10 seconds.
[root@web2 libexec]#


So that's a little different than what you were expecting.

Also I'm not able to get telnet working on from the XI box in putty. Below is what I get:

[root@localhost ~]# ping 192.168.1.41
PING 192.168.1.41 (192.168.1.41) 56(84) bytes of data.
64 bytes from 192.168.1.41: icmp_seq=1 ttl=64 time=0.382 ms
64 bytes from 192.168.1.41: icmp_seq=2 ttl=64 time=0.381 ms
64 bytes from 192.168.1.41: icmp_seq=3 ttl=64 time=0.392 ms
^C
--- 192.168.1.41 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2362ms
rtt min/avg/max/mdev = 0.381/0.385/0.392/0.005 ms
[root@localhost ~]# telent 192.168.1.41 5667
-bash: telent: command not found
[root@localhost ~]# telnet
telnet> 192.168.1.41 5667
?Invalid command
telnet> 192.168.1.41
?Invalid command
telnet> 192.168.1.41 5667
?Invalid command
mdzx111
Posts: 39
Joined: Tue Apr 17, 2012 2:27 pm

Re: CentOS 5.5 client install problem

Post by mdzx111 »

Ok sorry but I mistyped TELNET on the XI box in putty.

Here is what happens when I TELNET from XI in putty to 192.168.1.41 5667


[root@localhost ~]# telnet 192.168.1.41 5667
Trying 192.168.1.41...
telnet: connect to address 192.168.1.41: No route to host
[root@localhost ~]#
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: CentOS 5.5 client install problem

Post by scottwilkerson »

mdzx111 wrote:When I run:
cd /usr/local/nagios/libexec
./check_nrpe -H localhost

I get:


[root@web2 linux-nrpe-agent]# cd /usr/local/nagios/libexec
[root@web2 libexec]# ./check_nrpe -H localhost
CHECK_NRPE: Socket timeout after 10 seconds.
This looks like nrpe isn't running

Can we restart xinetd

Code: Select all

service xinetd restart
Then try the above command again, if that doesn't work, please send a copy of your /etc/xinetd.d/nrpe and also run the following and report the output

Code: Select all

ls -l /usr/local/nagios/bin/nrpe
Also, I am a little perplexed by your 192.168.1.41: No route to host on the telnet, yet you can ping the host...That's strange
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
mdzx111
Posts: 39
Joined: Tue Apr 17, 2012 2:27 pm

Re: CentOS 5.5 client install problem

Post by mdzx111 »

Ok so its all working now. Firewall was running as part of the problem and has been turned off.

This one is close. Now if we can only get other Ubuntu machines going, we'll be all set.

Thank you again!
Locked