Hi
I'm a Nagios XI and NCPA newbie.
I would like to conifgure a NCPA passive check.
We are using Nagios XI 5.2.3 and NPCA 1.8.1.
Plugin used (https://exchange.nagios.org/directory/P ... ll/details)
When I run the plugin check_windows_updates.ps1 as https://localhost:5693/api/agent/plugin ... pdates.ps1 I get the result below:
{
"value": {
"returncode": 2,
"stdout": "Updates: 11 critical, 0 optional\nSecurity Update for Windows Server 2008 R2 x64 Edition (KB3124000) \nSecurity Update for Windows Server 2008 R2 x64 Edition (KB3108664) \nSecurity Update for Windows Server 2008 R2 x64 Edition (KB3109560) \nSecurity Update for Windows Server 2008 R2 x64 Edition (KB3110329) \nSecurity Update for Windows Server 2008 R2 x64 Edition (KB3121918) \nSecurity Update for Windows Server 2008 R2 x64 Edition (KB3121212) \nSecurity Update for Windows Server 2008 R2 x64 Edition (KB3124001) \nCumulative Security Update for Internet Explorer 11 for Windows Server 2008 R2 for x64-based Systems (KB3124275) \nSecurity Update for Windows Server 2008 R2 x64 Edition (KB3123479) \nWindows Malicious Software Removal Tool x64 - January 2016 (KB890830) \nDefinition Update for Microsoft Endpoint Protection - KB2461484 (Definition 1.213.2668.0)"
}
}
But I can't make it this output via NRDP to Nagios XI.
Thank you in advance for your help.
NCPA - Configuring Passive Check
NCPA - Configuring Passive Check
Last edited by comfone on Thu Jan 14, 2016 2:39 am, edited 1 time in total.
Re: NCPA - Configuring Passive Check
I recommend you hit up the API of your windows host and navigate to the following location: https://windowsserver:5693/api/agent/plugin
Does your plugin appear in the API? If so, that's good - your command definition looks a little off, it should _likely_ be configured as follows:
%HOSTNAME%|WinUpdates = /agent/plugin/check_windows_updates.ps1
Most things in NCPA will be referenced using the API - let me know if the above helps! Thanks!
Does your plugin appear in the API? If so, that's good - your command definition looks a little off, it should _likely_ be configured as follows:
%HOSTNAME%|WinUpdates = /agent/plugin/check_windows_updates.ps1
Most things in NCPA will be referenced using the API - let me know if the above helps! Thanks!
Re: NCPA - Configuring Passive Check
Have you tried using any other powershell scripts as passive checks? The script requires passing arguments:
but your check is defined with no args:
I am not sure if this is the problem but we will try to recreate the issue in-house and get back to you.
Code: Select all
.ps1 = powershell -ExecutionPolicy Bypass -File $plugin_name $plugin_argsCode: Select all
%HOSTNAME%|WinUpdates = check_windows_updates.ps1Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: NCPA - Configuring Passive Check
Hi jolson
It works now.
My command definition was wrong.
After having changed it the way you recommended it worked.
Thank you.
It works now.
My command definition was wrong.
After having changed it the way you recommended it worked.
Thank you.