Connection refused

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
MPIvan
Posts: 213
Joined: Thu Nov 22, 2012 6:09 am

Connection refused

Post by MPIvan »

Hi all,
i have some problems that i cant find solution for it. I have 10 PC/Server hosts and for i dont know what reason, on one or two hosts i get this "Connection refused" status. Every 10 hosts are the same conf. (except the ip and hostname of course), all other hosts working ok and all the hosts have installed and configure the same NSClient++ same community etc. Also when i go to this two hosts that i get this connection refused (Host State Information) i get all OK but it shows me different i get mails that it is down ...

Also i try from the command to execute check_nt with different port numbers (just in case that it is not the port problem) and i got the same output ....
[root@mpnagios libexec]# ./check_nt -H 192.168.1.2 -p 12489 -s Testcomm -v CPULOAD -w 80 -c 90 -l 5,80,90,10,80,90
Connection refused
could not fetch information from server
[root@mpnagios libexec]# ./check_nt -H 192.168.1.3 -p 1248 -s Testcomm -v CPULOAD -w 80 -c 90 -l 5,80,90,10,80,90
Connection refused
could not fetch information from server
Im using Nagios 4.0.1 on CentOS 6.4 ...
Attachments
host state information.jpg
Service status.jpg
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: Connection refused

Post by sreinhardt »

The host OK state generally just means that you are able to ping it. As for nsclient, have you opened port 12489 on the remote systems firewall?

Code: Select all

nmap -p 12489 [hostname\IP]
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
MPIvan
Posts: 213
Joined: Thu Nov 22, 2012 6:09 am

Re: Connection refused

Post by MPIvan »

Its closed
[root@mpnagios objects]# nmap -p 12489 192.168.17.1

Starting Nmap 5.51 ( http://nmap.org ) at 2013-12-02 14:49 CET
Nmap scan report for 192.168.17.1
Host is up (0.011s latency).
PORT STATE SERVICE
12489/tcp closed unknown

Nmap done: 1 IP address (1 host up) scanned in 0.06 seconds
[root@mpnagios objects]#
is this port closed from nagios side ( CentOS default Firewall ) or from the address ( the pc that i want to monitor ) ? And interesting that all other hosts work on the same port number and it is ok ... just this two of them ...
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: Connection refused

Post by slansing »

It is closed on the windows host's side, you need to open 12489.
Locked