NCPA connection refused - RHEL6

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
Bala.Mutyam
Posts: 97
Joined: Wed Apr 29, 2020 12:18 pm

NCPA connection refused - RHEL6

Post by Bala.Mutyam »

Hi,

We are having an issue with NCPA on a Redhat 6 server and all nagios nagios checks failing with
UNKNOWN: An error occured connecting to API. (Connection error: '[Errno 111] Connection refused')
Port 5693 is already opened from NagiosXi to the agent and no SELinux & iptables.

Is there anything could cause this error? I tried re-installing etc.

All other RHEL6 servers working fine, this one server.
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: NCPA connection refused - RHEL6

Post by ssax »

What does this output from the XI server?
- Change X.X.X.X to the IP of the NCPA hos

Code: Select all

nmap -Pn -p5693 X.X.X.X
It could be Network IPS, Host IPS, or some other security software on the system impacting it.

Attach your ncpa.cfg from the remote system (not the XI server).

Include any errors from your ncpa_listener.log file.
Bala.Mutyam
Posts: 97
Joined: Wed Apr 29, 2020 12:18 pm

Re: NCPA connection refused - RHEL6

Post by Bala.Mutyam »

@ ssax : Hi - Thanks for the update; Here is the info:

Code: Select all

nmap -Pn -p5693 hostname
tarting Nmap 6.47 ( http://nmap.org ) at 2020-08-28 14:47 BST
Nmap scan report for hostname (host_ip)
Host is up (0.0030s latency).
PORT     STATE  SERVICE
5693/tcp closed unknown

Nmap done: 1 IP address (1 host up) scanned in 0.04 seconds

I have attache agent's ncpa.cfg file.

No error in the logs.

Code: Select all

2020-08-27 08:48:25,660 1288 INFO started
2020-08-27 08:48:25,667 1288 INFO Using SSL version TLSv1_2
2020-08-27 08:49:12,687 1288 INFO stopped
2020-08-27 08:49:13,229 1490 INFO started
2020-08-27 08:49:13,230 1490 INFO Using SSL version TLSv1_2
2020-08-27 08:55:24,537 1490 INFO stopped
2020-08-27 08:56:33,277 1915 INFO started
2020-08-27 08:56:33,278 1915 INFO Using SSL version TLSv1_2
2020-08-27 09:02:31,023 1915 INFO stopped
2020-08-27 09:02:31,560 2479 INFO started
2020-08-27 09:02:31,561 2479 INFO Using SSL version TLSv1_2
2020-08-27 09:35:15,859 2479 INFO stopped
2020-08-27 10:06:50,849 3499 INFO started
2020-08-27 10:06:50,850 3499 INFO Using SSL version TLSv1_2
2020-08-27 10:10:22,667 3499 INFO stopped
2020-08-27 10:12:31,613 3763 INFO started
2020-08-27 10:12:31,614 3763 INFO Using SSL version TLSv1_2
2020-08-27 13:17:05,228 3763 INFO stopped
2020-08-27 13:17:15,780 5342 INFO started
2020-08-27 13:17:15,781 5342 INFO Using SSL version TLSv1_2
2020-08-28 08:54:29,955 5342 INFO stopped
2020-08-28 08:56:05,002 15752 INFO started
2020-08-28 08:56:05,002 15752 INFO Using SSL version TLSv1_2
You do not have the required permissions to view the files attached to this post.
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: NCPA connection refused - RHEL6

Post by ssax »

Code: Select all

5693/tcp closed unknown
That means the service isn't even listening.

Try editing your ncpa.cfg and add these under the listener section:

Code: Select all

ip = 0.0.0.0
port = 5693
Then restart the ncpa_listener service:

Code: Select all

service ncpa_listener restart
Then test again:

Code: Select all

nmap -Pn -p5693 X.X.X.X
Bala.Mutyam
Posts: 97
Joined: Wed Apr 29, 2020 12:18 pm

Re: NCPA connection refused - RHEL6

Post by Bala.Mutyam »

@ssax - Hi, thanks for the update. I have added those 2 lines and restarted the ncpa service and it's working. Really strange, as i mentioned other servers working without adding.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: NCPA connection refused - RHEL6

Post by scottwilkerson »

Bala.Mutyam wrote:@ssax - Hi, thanks for the update. I have added those 2 lines and restarted the ncpa service and it's working. Really strange, as i mentioned other servers working without adding.
Great!

Locking thread
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked