Hi, I have a custom EXE/Script Advanced sensor that runs a perl script and returns XML. I've reduced it to an *extremely* basic script but I still am getting this error: Error reading response: Invalid XML (missing /prtg)

When I run this from the command prompt on the PRTG server that has the script it clearly is returning the </prtg> tag:

<prtg> <text>Counters retrieved successfully</text>

</prtg>

I've ticked the 'write results to logs' but it does not appear to have any effect, I've checked the various subfolders of "programdata" but it doesn't seem to be writing anything there.

This is server 2008 x64 in a VM, PRTG 14.2.9.1799. It has the MSFT .NET 4.51 framework installed.

And to further confound me, I have another similar script on this server that works fine! (perl returning XML and terminating with </prtg>).

Any pointers? I must be missing something obvious here! Thanks, Tim


Article Comments

Hello,

thank you very much for your KB-Post. What looks strange is, that the script does not seem to return any numerical value, or channel value. Or is this just an excerpt here?

best regards.


May, 2014 - Permalink

Hi, Yes, originally it was returning <result></result> tags as well, but I removed everything to the absolute bare bones trying to figure out where the problem was, and still it does not work. Thanks.


May, 2014 - Permalink

Can you please show the full XML?


May, 2014 - Permalink

To be clear: That *IS* the full XML. There is nothing else. That's why I am posting here: all the script returns at this point is the opening/closing <prtg> tags, and a single <text> tag, and *still* I get this error. I don't get it....

Tim


May, 2014 - Permalink

Then please have it include a proper result (sensor value).


May, 2014 - Permalink