I am trying to monitor status of an HP p2000 using the technique listed here http://www.remilner.co.uk/?p=276

This works, but many of the values returned from the p2000 command line do not display as numbers, they display as text statuses, for example they return the value "OK"

In turn, my XML looks like this

<prtg> <result> <channel>Power Supply 1</channel> <value>OK</value> </result> </prtg>

In the prtg monitor this shows up as just as the number Zero in the table of channels for my custom Sensor.

Is it possible for the <value></value> field to to have a non numeric value?

I have searched the faq on line and I cannot find any examples of using non numbers in this field.


Article Comments

I'm afraid the value field has to be provided with a numerical entry.


Jan, 2013 - Permalink

If you modify your custom sensor, to return numeric values instead of text: i.e. if ($value -eq "OK") { Write-Host "<value>1</value>" } else { Write-Host "<value>0</value>" }

then you can use the PRTG lookups feature to recreate a meaningful message for the value

For more information, see PRTG Manual: Define Lookups.


Jun, 2013 - Permalink

We always love to see if one customer helps another. In this case the answer is absolutely perfect. At the time, when Patrick answered the ticket, the lookup feature was not yet available. Thank you very much!


Jun, 2013 - Permalink