I have a script that gets the status of services. Currently, sensor sets value of 0 (UP state) when service is running. How can I set the sensor to Down state if the service is stopped?
Setting sensor status for EXE/Script Advanced Sensor
Modified on 2025-06-10 15:12:55 +0200
Disclaimer:
The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.
The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.
Hello there,
You can define the various value for sensor state. Such as "0"=Ok(Up), "1"=Warning, "2"=Error(Down). You could also set a limit as an example, if the sensor receive the value 1 when the service is stopped so you can set a upper limit of 0,1. ? For more information, I would suggest you to refer to the following manual: https://www.paessler.com/manuals/prtg/custom_sensors
Regards,
Feb, 2021 - Permalink