HP IDOL Queries

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
zovy
Posts: 26
Joined: Fri Dec 19, 2014 1:17 pm

HP IDOL Queries

Post by zovy »

I would like to monitor specific XML output from IDOL content engines. I would like to both extract specific values to display when OK and alert when value is greater than X. How could I go about this? Values (lines 14 & 19) would be for directory and documents. An example content query would be sent via a web browser

Code: Select all

http://192.168.1.1:120/a=getstatus
and the browser results would produce XML output that looks like

Code: Select all

<autnresponse xmlns:autn="http://schemas.autonomy.com/aci/">
<action>GETSTATUS</action>
<response>SUCCESS</response>
<responsedata>
<product>IDOL Server</product>
<version>10.8.0</version>
<build>1187308</build>
<licensed_languages>UNLIMITED</licensed_languages>
<indexport>12</indexport>
<indexport_ssl_enabled>false</indexport_ssl_enabled>
<queryport>-1</queryport>
<aciport>122</aciport>
<serviceport>123</serviceport>
<directory>C:\content</directory>
<querythreads>0</querythreads>
<acithreads>8</acithreads>
<termsperdoc>50</termsperdoc>
<suggestterms>40</suggestterms>
<documents>4366568</documents>
<document_sections>4366568</document_sections>
<committed_documents>4660488</committed_documents>
<deleted_sections>293920</deleted_sections>
<full>false</full>
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: HP IDOL Queries

Post by hsmith »

You could pretty easily write a bash script to do this.

Something like:

curl the page
use head / tail /cut to get the information you want
use an if statement to exit 0 / 1 / 2 depending on the information you get.

Am I making sense?
Former Nagios Employee.
me.
zovy
Posts: 26
Joined: Fri Dec 19, 2014 1:17 pm

Re: HP IDOL Queries

Post by zovy »

Somewhat but not sure how I would get NAGIOS to interact with any of it would be the problem. I could sed/awk the results of the curl as well but I have no idea how I would have nagios initiate the script to run and then return the results and determine OK, WARN, CRIT.
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: HP IDOL Queries

Post by hsmith »

You would write the script to /usr/local/nagios/libexec/myscript.sh
Then you could set up a command in XI using CCM to run myscript.sh
Then set up a service check to use that check command

At least, I think that is what you are asking.
Former Nagios Employee.
me.
Locked