You heard it here last, to use sog‘s catchphrase. Haven’t you always wanted to track down the runaway process that was sucking up all your disk I/O? Now you can, with iotop. It’s a simple Python script, not even a full-out application. iotop uses the I/O accounting in newer 2.6 kernels >=2.6.20 (check whether /proc/self/io exists to see whether you’ve got it enabled) and requires at least Python 2.5 for AF_NETLINK sockets. Here’s what it looks like (click for larger image):
It shows overall disk read and write in MB/s. Per-process, it shows disk read and write speeds as well as percentage of time spent swapping in and percentage of time spent while waiting on I/O. In other words, it rocks.
To install it on Gentoo:
You might need to sync your tree because I just added it. It’s still got testing keywords, so if you’re running stable, do this:
echo =dev-lang/python-2.5* >> /etc/portage/package.keywords
echo sys-process/iotop >> /etc/portage/package.keywords
12 thoughts on “The tool you wished exists actually does: iotop”
Someone hasn’t heard of atop.
I installed it to take a look, and honestly I find it pretty ugly and harder to use with the way it displays things. For example its column labels are nonobvious, and less readable because they’re sort-of-abbreviated and have no spaces, and the same goes for the lack of separation between the units and the numbers in the data.
Wow, this is exactly what I’ve been wanting all this time!
Regarding kernel options: I enabled TASKSTATS and its dependents, although probably only TASK_IO_ACCOUNTING is needed. Confusingly, the help text claims these options are experimental, even though they don’t depend on EXPERIMENTAL.
missing info that would be very useful: disk seeks
atop?? gotta give it a try for sure
thanks for the little utility
I am really worried by the linuxdcpp client’s disk usage
any comments on torrent / DC++ clients and disk usage by them??
I think those small chunks really eat your disk
This post isn’t really about disk usage or layout, just activity, so I don’t really have any comments on that. I don’t really use BitTorrent for anything.
I believe blktrace is good for figuring out what’s actually happening on the block device, although I have not used it myself.
Completely Off Topic, but couldn’t resist to ask.
Did you get those fonts on a terminal running on Linux or on Mac?
How did you get those on a Linux Box?
You have to buy them, and they’re expensive. TheSans Mono Condensed
Amazing tool. I actually never felt the need for something like this, but now that it exists I can think of at least a handful of cases where it could be useful directly or indirectly. I imagine that the same infrastructure could be used for performance regression tests for example.
Sidnei, thanks for the reminder that I have a blog, and I should write stuff on it. =)
Nice info dude, after reading it, if run emerge iotop. this tool is The tool I wished exists , thx
Comments are closed.