I've created a custom script sensor, with a custom value lookup but the sensor only returns the data associated with the channel, and not the reference text. Neither my lookup or sensor fails. I have recreated it a number of times but no joy.
Here is an example of the sensor data: <?xml version="1.0" encoding="Windows-1252" ?>
<prtg>
<result> <channel>Status</channel> <unit>Custom</unit> <mode>Absolute</mode> <showChart>1</showChart> <showTable>1</showTable> <value>2</value> <ValueLookup>ms.sql.replication.state</ValueLookup> <LimitMode>1</LimitMode> </result>
<result> <channel>Latency</channel> <unit>TimeSeconds</unit> <mode>Absolute</mode> <showChart>1</showChart> <showTable>1</showTable> <warning>60</warning> <value>5</value> <LimitMaxError>80</LimitMaxError> <LimitMaxWarning>37</LimitMaxWarning> <LimitWarningMsg>Latency is Degraded.</LimitWarningMsg> <LimitErrorMsg>Latency is Critical.</LimitErrorMsg> <LimitMode>1</LimitMode> </result>
</prtg>
And here is my lookup: <?xml version="1.0" encoding="UTF-8"?> <ValueLookup id="ms.sql.replication.state" desiredValue="4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="PaeValueLookup.xsd"> <Lookups> <SingleInt state="Ok" value="4"> Idle </SingleInt> <SingleInt state="Ok" value="1"> Started </SingleInt> <SingleInt state="Error" value="2"> Stopped </SingleInt> <SingleInt state="Ok" value="3"> InProgress </SingleInt> <SingleInt state="Warning" value="5"> Retrying </SingleInt> <SingleInt state="Failed" value="6"> Failed </SingleInt> </Lookups> </ValueLookup>
Add comment