I've created a custom EXE/XML sensor which, in addition to the sensor's state, should include a message to be shown in the PRTG interface. As far as I understand from the PRTG manual, this is what the <text> tag is intended for. Regarding this tag, the PRTG API Custom Sensor's section explains the following: "Text the sensor returns in the Message field with every scanning interval." However, when I supply the message to be shown via the <text> tag (included within the <prtg> tag, but outside of <result>, as required by the API), I see it being included in the XML message in debug output, but the message won't show up in PRTG. Only the default message from the value lookup is shown. Is there anything I'm missing?


Article Comments

OK, update: I just figured out the message supplied via the <text> tag IS shown if I set the value lookup setting of the primary channel to use none. Now I can see the message, but have lost the status information. How can I have text messages from the sensor being displayed AND status translation from a value lookup?


Dec, 2014 - Permalink

Hello Ages,

All sensors do only have one message field. Your script forwards a message to PRTG, but your defined lookup will overwrite this message with the text you entered in the lookup. You can either display the message of the script, or the message of the lookup file.

Best regards


Dec, 2014 - Permalink

Hi,

thanks for clarification. I don't want the status description from the value lookup being passed as sensor message. I just need the lookup to provide status information for the channel, and I definitely want the sensor message being taken from the sensor result's <text> tag. How to do that?


Dec, 2014 - Permalink

Hi,

Then you cannot use a lookup as the lookup will always overwrite the message of your script. The only sensor message which will be passed is if the sensor returns an "okay" state. Then you will see the sensor message in the message field and the lookup message below the lookup symbol.


Dec, 2014 - Permalink

So the sensor can show text messages when in state "OK", but not when in state "Error" or "Warning"?


Dec, 2014 - Permalink

This is the current state, yes. I'll forward your request as a feature request for future versions of PRTG. Please bear with us.


Dec, 2014 - Permalink