NCP Checks failing after NCP Agent upgraded to 2.1.8

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
Sampath.Basireddy
Posts: 252
Joined: Wed Dec 14, 2016 12:30 pm

NCP Checks failing after NCP Agent upgraded to 2.1.8

Post by Sampath.Basireddy »

After the NCP Agent is upgraded to 2.1.8 on few of our servers, NCP Checks are failing with error "UNKNOWN: Error occurred while running the plugin. Use the verbose flag for more details."
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: NCP Checks failing after NCP Agent upgraded to 2.1.8

Post by lmiltchev »

Can you show us the actual command, run from the command line along with the output of it for one of the failing checks?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Sampath.Basireddy
Posts: 252
Joined: Wed Dec 14, 2016 12:30 pm

Re: NCP Checks failing after NCP Agent upgraded to 2.1.8

Post by Sampath.Basireddy »

Here it is:

Code: Select all

[root@gmp1 libexec]# /usr/local/nagios/libexec/check_ncpa.py -H server1.ux.corp.local -t ################ -P 5693 -M 'disk/logical/|var/' -u M -w 90 -c 95
UNKNOWN: Error occurred while running the plugin. Use the verbose flag for more details.

Code: Select all

[root@gmp1 libexec]# curl -k -XGET "https://localhost:5693/api/system/agent_version?token=################"
{
    "agent_version": "2.1.8"
}[root@gmp1 libexec]#
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: NCP Checks failing after NCP Agent upgraded to 2.1.8

Post by lmiltchev »

Can you try removing the "/" after "var" to see if this is going to fix your issue?

Example:

Code: Select all

/usr/local/nagios/libexec/check_ncpa.py -H server1.ux.corp.local -t ################ -P 5693 -M 'disk/logical/|var' -u M -w 90 -c 95
If this doesn't work, run the check with the "-v" flag for increased verbosity and show the output. Thanks!
Be sure to check out our Knowledgebase for helpful articles and solutions!
Sampath.Basireddy
Posts: 252
Joined: Wed Dec 14, 2016 12:30 pm

Re: NCP Checks failing after NCP Agent upgraded to 2.1.8

Post by Sampath.Basireddy »

Thank You @lmiltchev, that took care of the issue.

Is this some new limitation?
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: NCP Checks failing after NCP Agent upgraded to 2.1.8

Post by lmiltchev »

I am not sure if it is a "limitation". When logging to the API (in the GUI), and checking the correct syntax, this is what you see - 'disk/logical/|var'. There is no "/" after "var".

What is the NCPA version that you upgraded from? It's possible that the syntax was changed, but I do not remember if the "/" was present in the older versions. If I knew the version number you upgraded from, I could test it in-house, and check with our developers on that.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Sampath.Basireddy
Posts: 252
Joined: Wed Dec 14, 2016 12:30 pm

Re: NCP Checks failing after NCP Agent upgraded to 2.1.8

Post by Sampath.Basireddy »

NCP Agent was upgraded from 2.1.6 to 2.1.8.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: NCP Checks failing after NCP Agent upgraded to 2.1.8

Post by lmiltchev »

I can verify that in NCPA ver. 2.1.6, the commands worked with or without the "/" at the end, which was a bug that was fixed in the newest versions of the agent. You should not have the trailing slash present at the end.

I will be closing this topic now. If you have any further, unrelated questions please start a new thread. Thank you!
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked