I have created a python advanced custom sensor that returns about 12 channels showing Total ram Free ram Free ram % Total disk Disk free Disk free % Size of /opt Size of / var/log Size of /~ Load 1 min Load 5 min Load 15 min Running process (parameter passed in) Queue length of redis key And mysql database size Finally mysql avg querie time
The script runs perfectly when called manually and returns perfect xml.
When run by prtg it works fine too 95% of the time the rest of the time every 20 times or so I get no valid result from shell. The result saved to disk contains no data at all.
I simulated load on the server using stress. And the sensor failed every time although I could log in no problem and run the script.
Also the script takes less that 2 seconds to run prob less than 1 mostly.