Hi there I have a script on my Varnish server that outputs the number of connections to my Varnish instance. This is done using the following command:
varnishstat -1 -f client_req | awk '{ print $2 }'
PRTG finds my script, which is in /var/prtg/scripts, and furthermore, it executes it and returns the correct number of connections. But, the sensor errors out with "response not well-formed".
Response not wellformed: "2321 " (code: PE132)
The sensor is the SSH script sensor - integer defined. PRTG 12.
My question is; what is not well formed about the output? I have seen the value:message reply given in https://www.paessler.com/knowledgebase/en/topic/31683-custom-script-sensor-error, but I would like someone to elaborate on that if it applies to my question.
Thank you.
Article Comments
OK, but this is a "up or down" approach you are taking. I am not doing that. I have something else taking care of the health checks. I just want to graph out the values returned from my script. Can I do that?
Oct, 2012 - Permalink
Hi,
yes, you can deliver back any value you want in the "value" (float or integer) which then will be contained in the graph. The script only should show the possibilities what can be done with the sensor.
Best regards
Oct, 2012 - Permalink
Oki, great :-) I will get started. Appreciate the feedback. Thank you. I will make sure to update the post with my working solution.
Oct, 2012 - Permalink
Good morning
after update to the version 14.2.10.2114, my powershell script returns this error. Before of update, the powershell worked correctly.
This is my code:
write-host 2, "Error" $message
Jun, 2014 - Permalink
@BORJA RODRIGUEZ: Would you mind opening a new thread for this as your issue seems to be related to Powershell and this thread refers to SSH scripts?
Thank you!
Jun, 2014 - Permalink
Hi Kenneth Fossum: Could you please share the solution you applied to output format to the command you wanted to execute ?. I have the same problem as you say.
Dec, 2016 - Permalink
Hi,
first, please note that the article you are referring to is only addressing script sensors on Windows Systems where the return has to be
On Linux Systems and with the SSH Script Sensor you will have to return the values in a different way. Please find below the notation for the return values in the SSH Script Sensor:
Where return code can be
For a script example, please refer to this article as well.
Best regards
Oct, 2012 - Permalink