scottchiefbaker / dool

Python3 compatible fork of dstat
GNU General Public License v3.0
332 stars 64 forks source link

top_io_adv plugin is not working properly #25

Closed SSoft7 closed 1 year ago

SSoft7 commented 2 years ago
SUMMARY

The plugin --top-io-adv is not working properly. Take the following command for example ./dool -dD sda --top-io-adv This command will show IO processes from all of my hard disks instead of just sda. Any idea what's wrong here? Am I doing anything wrong or the tool is just broken?

ISSUE TYPE
DSTAT VERSION
<!--- Paste verbatim output from “dstat --version” here between tripple quotes -->
Dool 1.0.0
Latest from github
OS / ENVIRONMENT

Ubuntu Bionic

STEPS TO REPRODUCE
./dool -dD sda --top-io-adv
EXPECTED RESULTS
see SUMMARY
ACTUAL RESULTS
see SUMMARY
scottchiefbaker commented 1 year ago

This top-io-adv plugin does not have the ability to read a specific disk currently. Pull requests are welcome.

scottchiefbaker commented 1 year ago

Looking in to this further... The purpose of the top-io-adv plug-in is to find the process that is using the most disk IO. This is accomplished by looking at /proc/$PID/io. Looking at that file I see:

$ cat /proc/2192/io
rchar: 53993457190
wchar: 1975163224
syscr: 20555066
syscw: 6998791
read_bytes: 4357413531648
write_bytes: 181883109376
cancelled_write_bytes: 163840

There is no way to determine what disk a given process is reading/writing to. It's just an aggregate total. Going to have to close this CANTFIX unless someone can show me how to do what the OP is suggesting.