Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Does anyone have experience with a tool that can provide an indication of disk IO load by filesystem path.

I use to 'iostat' utility, frequently, to learn how much disk activity is taking place on a Linux host. 'iostat' provides a per-device breakdown, so you can see activity on a particular block device. But it doesn't go any deeper than that--you can't, for instance, query the write load generated by 'httpd' in the directory '/var/log/httpd/'.

share|improve this question
    
You can't really monitor by filesystem path since by the time the kernel gets to play with the block device there's no information on where in the tree the request is for. Knowing which process is doing the damage, on the other hand, gives you someone to strace, which usually amounts to the same thing in the end. –  womble Jun 12 '09 at 23:38
3  
Based on these answers, I've tried both htop and iotop, and it looks like they both have the basic functionality to break down IO rates per process. Some big differences: * htop has lots of functions and measures all kinds of system statistics, whereas iotop only looks at per-process IO rates. * Using iotop for the first time is a little easier, since it's simpler. * iotop's '-o' ("only") flag hides processes not engaging in IO, which is VERY useful when troubleshooting disk hogs. I couldn't find something similar in htop. Both tools work, but I'll use iotop, for this. –  Ryan B. Lynch Jun 23 '09 at 19:19
1  
there's also atop, which displays per-process live and historical data interactively. –  Tobu Jun 14 '10 at 6:00
add comment

3 Answers 3

up vote 15 down vote accepted

You can use iotop for that purpose.

I works like normal top, I cannot say much more. Most distributions will have it packaged, but here is its homepage. You will need a recent kernel.

share|improve this answer
    
iotop is brilliant! –  Joseph Kern Jun 12 '09 at 21:19
add comment

Using htop do the following.

htop
F5 (Tree view)
F2 (Setup)
Select columns
Select RBYTES WBYTES
F10 (Done)

And there you go, per process disk I/O, in real time.

share|improve this answer
    
Outstanding answer –  Dave Cheney Jun 13 '09 at 10:45
add comment

Collectl can also show process I/O loads but since it can also monitor virtually all your other system resources you get it all in one tool. For example, you can look at the top i/o or cpu processes right now along with disk, network, etc. BUT you can also play back historic data and display the same types of data. Further, there are actually 7 different process I/O provided by the kernel. Collectl can show them all and even let you sort on them. -mark

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.