Check for updates using the NCPA agent

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
jakai
Posts: 21
Joined: Wed Oct 21, 2020 2:39 am

Re: Check for updates using the NCPA agent

Post by jakai »

I am sending the result of the commands here. Is that enough for you?
You do not have the required permissions to view the files attached to this post.
jakai
Posts: 21
Joined: Wed Oct 21, 2020 2:39 am

Re: Check for updates using the NCPA agent

Post by jakai »

And here I send the files you wanted.
You do not have the required permissions to view the files attached to this post.
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Check for updates using the NCPA agent

Post by pbroste »

Hello @jakai

Thanks for following up, and sending over the info. We see that we are able to get a 'check_ncpa' --list from the specified host. This means that the check is able to resolve, establish a connection with the specified host, and list out the results.

We see that the command was run using jakai user account as sudo (super user). Let's verify that the command will run when logged with the 'nagios' user account.

Code: Select all

su -l nagios
Then run the following:

Code: Select all

/usr/local/nagios/libexec/check_ncpa.py -H 192.168.203.34 -t b08TjIck2Rd2 --list
If we see a --list resulting from the 'check_ncpa.py' command while logged in with the 'nagios' user account then we are ready to test the original command provided.

From your previously posted screenshot, you are using the plugin check_rpm.

Verify that the 'check_rpm' check script is located in the 'ncpa' plugins directory (typically located: /usr/local/ncpa/plugins/) on the '192.168.203.34'.

Let's run the following to verify:

Code: Select all

/usr/local/nagios/libexec/check_ncpa.py -H 192.168.203.34 -t b08TjIck2Rd2 -M plugins/check_rpm <yourargshere>
When we get functioning results we can then enter the check into the web console in the Core Configuration Manager.

Thanks,
Perry
jakai
Posts: 21
Joined: Wed Oct 21, 2020 2:39 am

Re: Check for updates using the NCPA agent

Post by jakai »

Good day,
the last command does not work on either the nagios server or 192.168.203.34. I'm sending screens.

In the first screen you can see that the file is in its place at 192.168.203.36. The other two that the last command does not work.
You do not have the required permissions to view the files attached to this post.
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Check for updates using the NCPA agent

Post by pbroste »

Hello @jakai

Thanks for following up, and providing the screenshots.

Want to adjust the file ownership on the device that is executing the 'check_rpm' from the plugin directory.

Code: Select all

chown nagios:nagios /usr/local/ncpa/plugins/check_rpm
Verify the plugin directly via shell on device:

Code: Select all

/usr/local/ncpa/plugins/check_rpm
Then verify via 'check_ncpa' directly from the Nagios XI server by:

Code: Select all

su -l nagios
/usr/local/nagios/libexec/check_ncpa.py -H <hostaddresshere> -t <yourtokenhere> -M plugins/check_rpm
Thanks,
Perry
jakai
Posts: 21
Joined: Wed Oct 21, 2020 2:39 am

Re: Check for updates using the NCPA agent

Post by jakai »

I have error. Don't you know what it can be?
You do not have the required permissions to view the files attached to this post.
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Check for updates using the NCPA agent

Post by pbroste »

Hello @jakai

Thanks for following up with the screenshot; as we know the 500 error is pretty generic. "Means that the server encountered an unexpected condition that prevented it from fulfilling the request."

Noticed that there was a 'super-user' (sudo) prepended to the command command that we provided and want to find out the results on the command with out "sudo" /usr/local/nagios/libexec/check_ncpa.py -H <hostaddresshere> -t <yourtokenhere> -M plugins/check_rpm

If the issue persists we would want you to verify that security applications, firewalls, proxy, routing, and other issues are not getting in the way. The option to look at the traffic while running the 'ncpa' service check:

Code: Select all

tcpdump -s 0 -i any port 5693 -w output.pcap
Thanks,
Perry
jakai
Posts: 21
Joined: Wed Oct 21, 2020 2:39 am

Re: Check for updates using the NCPA agent

Post by jakai »

Hello,

Again the same result. And the command you entered was not recognized.
You do not have the required permissions to view the files attached to this post.
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Check for updates using the NCPA agent

Post by pbroste »

Hello @jakai

Thanks for following up with the screenshot details, we see the same results, and looks like you will require to install the 'tcpdump' package from your distro's repository. Most likely one of these:

Code: Select all

yum install tcpdump
or

Code: Select all

apt install tcpdump
Once installed you can continue and run the 'tcpdump' commands.

Thanks,
Perry
jakai
Posts: 21
Joined: Wed Oct 21, 2020 2:39 am

Re: Check for updates using the NCPA agent

Post by jakai »

Good day,
Thank you, I am sending a screen screen with the result of the command.
You do not have the required permissions to view the files attached to this post.
Locked