site  contact  subhomenews

Kernel task_delayacct fix for ioptop-py

April 29, 2024 — BarryK

Iotop monitors input/output activity. In EasyOS and QV you will find it in the System menu. I wrote about it in 2023:

https://bkhome.org/news/202310/iotop-py-compiled-in-oe.html

This is what it looks like:

img1

...see the message along the bottom of the window. "CONFIG_TASK_DELAY_ACCT" is actually enabled in the kernel; however, disabled by default, and has to be turned on, either on the kernel commandline or by 'sysctl' after bootup. The reason for disabling it by default is that it imposes a i/o performance hit.

I have modified the wrapper, /usr/bin/iotop-wrapper:

#!/bin/ash
if [ -e usr/bin/iotop-py ];then
IOTOPEXE='iotop-py'
else
IOTOPEXE='iotop'
fi
sysctl kernel.task_delayacct=1
urxvt -bg '#f0f0f0' -fg black -name iotop -fn 'xft:Roboto Mono:style=Regular:pixelsize=14' -fb 'xft:Roboto Mono:style=Bold:pixelsize=14' -e ${IOTOPEXE} -o -a
sysctl kernel.task_delayacct=0

Now, iotop-py displays all information. Here is the project homepage:

http://guichaz.free.fr/iotop/

This fix applies to both EasyOS and QV.  

Tags: easy