Page 2 of 2
Re: UNKNOWN: An error occured connecting to API. (Connection
Posted: Fri Nov 05, 2021 9:00 am
by preethu.d
Hi Perry,
It shows active (exited). i have attached the screenshot.
For the below command, do you want to check this from remote host or from Nagios server ?
"yourhostaddresshere" is it Nagios IP or remote host IP ?
Can you please explain.
/usr/local/nagios/libexec/check_ncpa.py -H yourhostaddresshere -P 5693 -t yourtokenhere -M 'disk/logical/|boot/used_percent' -w 80 -c 90
Regards,
Preethu
Re: UNKNOWN: An error occured connecting to API. (Connection
Posted: Fri Nov 05, 2021 3:02 pm
by pbroste
Hello
@preethu.d
Thanks for following up with the screenshot and details.
Appears that the 'ncap_listener' is complaining about running as daemon, and it appears that the
ncpa agent is installed in a non-default directory? How was the 'ncpa agent' installed? Typically we see in '/usr/local/ncpa/....'
Let's first list some python stuff:
Then;
Instead of launching the 'ncpa_listener' as a daemon we will go ahead and run as process. See if it complains:
Code: Select all
/usr/local/ncpa/ncpa_listener --start -n &
(your path may differ)
Then;
Code: Select all
/usr/local/ncpa/ncpa_listener --status
(your path may differ)
To find the 'ncpa_listener' running process:
Please let us know how things look,
Perry
Re: UNKNOWN: An error occured connecting to API. (Connection
Posted: Wed Nov 10, 2021 2:19 am
by preethu.d
Hi Perry,
I have executed the steps, attached the screenshot. Please check.
Regards,
Preethu
Re: UNKNOWN: An error occured connecting to API. (Connection
Posted: Wed Nov 10, 2021 2:03 pm
by pbroste
Hello
@preethu.d
Thanks for following up, I did not catch this earlier, but a colleague pointed out that this was an issue with ipv6 integration and is fixed in the latest stable agent version - 2.3.1.
Found here:
https://www.nagios.org/ncpa/#downloads
Thanks,
Perry
Re: UNKNOWN: An error occured connecting to API. (Connection
Posted: Sat Nov 13, 2021 5:28 am
by preethu.d
Hi Perry,
I installed latest agent and it is working now.
Thanks for the help.
You can close this thread.
Regards,
Preethu
Re: UNKNOWN: An error occured connecting to API. (Connection
Posted: Mon Nov 15, 2021 9:58 am
by pbroste
Hello
@preethu.d
Excellent, please let us know if you need anything further. Locking.
Thanks,
Perry