run custom scripts using NCPA passive

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
microdata.dk
Posts: 17
Joined: Wed Feb 23, 2011 9:43 am

run custom scripts using NCPA passive

Post by microdata.dk »

Hi.

Is it possible to run at custom script (.ps) when using NCPA 2.x in passive mode? I use NagiosXI

I have a .ps script that check the status of last Windows Update, that works i Active mode :-)

Thx

Dennis Vind Nielsen
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: run custom scripts using NCPA passive

Post by tmcdonald »

Plugins really shouldn't know or care whether they are being run as active or passive, so it should work just fine.
Former Nagios employee
microdata.dk
Posts: 17
Joined: Wed Feb 23, 2011 9:43 am

Re: run custom scripts using NCPA passive

Post by microdata.dk »

1
Last edited by microdata.dk on Mon Jul 23, 2018 12:29 pm, edited 1 time in total.
microdata.dk
Posts: 17
Joined: Wed Feb 23, 2011 9:43 am

Re: run custom scripts using NCPA passive

Post by microdata.dk »

tmcdonald wrote:Plugins really shouldn't know or care whether they are being run as active or passive, so it should work just fine.
But how do you "activate" the script when in passive mode?

In the Active mode I a have er service "check_xi_ncpa.py" that tell the NCPA client to run the script
npolovenko
Support Tech
Posts: 3457
Joined: Mon May 15, 2017 5:00 pm

Re: run custom scripts using NCPA passive

Post by npolovenko »

@microdata.dk, This article should help you set up passive checks.
https://www.nagios.org/ncpa/help/2.1/passive.html
And here's how to generate the "definition" for your passive check:

1. Put your custom script in the Plugins folder:

Code: Select all

C:\Program Files (x86)\Nagios\NCPA\plugins
or

Code: Select all

C:\Program Files\Nagios\NCPA\plugins
Depending on your installation.

2. Type in the ncpa agent IP address in the web browser and add :5693 and then do the following:
Untitled.png
This should generate the passive check definition for you.
You do not have the required permissions to view the files attached to this post.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Locked