How can someone add a sensor to monitor disk I/O in Linux?
There are only 2 answers using WMI for Windows but nothing for Linux and this post here: https://kb.paessler.com/knowledgebase/en/topic/36813-how-to-monitor-disk-latency-on-a-linux-server
Seems more like a hack. If we need to create custom scripts then why would you even need PRTG in the first place to do the job....
I have another open source monitoring system and I can add disk measurements just fine. With PRTG I can only use free space, swap, etc, only sensors related to very basic usage. Nothing that will measure disk performance which is kind of odd. It seems nothing related to monitoring drives in Linux can be added or maybe I can´t find this sensors.
Drives are an important part in any IT infrastructure as they tend to be the slowest equation in servers and with most problems, so sensors for drives should be a high priority.
Article Comments
Can you tell me if there is a way to write this script so that it will not display 50 Channels? I only need specifically stats on sda sdb sdc
Jan, 2015 - Permalink
Sorry, these scripts come without further warranty and support. You would need to adjust them yourself for your own use-case.
Jan, 2015 - Permalink
Hi, the link to the script above is dead here. Can you fix it please? Thank you.
Sep, 2015 - Permalink
We are working on trying to find this data. I will post a new link here once we have found them.
Sep, 2015 - Permalink
I updated the link above but here it is again:
https://media.paessler.com/kb/2015/iostat_scriptsxml.zip
Please let me know if you have any trouble downloading this.
Oct, 2015 - Permalink
Dear Volker,
You are right, the old way of accessing scripts on the linux machine is outdated. Now you can use our new SSH-Script-Advanced-Sensor that was introduced with version 12.4.7.3473.
The main problem with linux-sensors is the huge variety of small differences between the distributions. By using a set of scripts that can be adopted you can retrieve all values that can be retrieved programatically.
In the near future we will create a 'suite' of (example-)scripts as well as a 'library' that can be used from other scripts to produce the needed xml-result in an easy way.
In the meantime and to have an example how it works for retrieving IO-Stats you can use the files found at our Download-site. The scripts in the zip-file are pretty straight forward and can be adopted to your needs.
The only dependency for the script is the availability of the 'iostat'-command at the linux-machine. On most distributions it is part of the 'sysstat'-package.
Unfortunately there are some differences in the output depending on the version of the sysstat-package. You have to find out, which version of sysstat is installed on your machine (e. g. 'dpkg -l sysstat') and use the according script from the zip-file.
On the Linux-site you need to create a '/var/prtg/scriptsxml'-directory and copy the script into it as 'iostat.sh'. Don't forget to make it executable for the user you are connecting from prtg!
After that you can add the 'ssh-script-advanced'-sensor to your linux-device in prtg and select the 'iostat.sh'-script from the dropdown-list. If you have set up your ssh-credentials for this machine there are no further parameters needed.
Kind regards
Dec, 2012 - Permalink