Random Project

Fix for latest sysstat in Debian 11 (Bullseye)

Great plugin, but I did find one issue. When I upgraded one of my servers to Debian 11 this plugin stopped working. It appears to be an issue with an updated version of iostat. To fix just edit the following lines from around line 234.

TMPX=$($iostat $disk -x -k -d 10 2 $samples | grep $disk | tail -1)
TMPD=$($iostat $disk -k -d 10 2 $samples | grep $disk | tail -1)

All I did was add a 2 after the 10 so that only 2 lines are returned to get the stats out. So far it seems to be working just fine. I hope this helps.