0

I have an SSD and a hard disk in one computer. I use mountpoints and symlinks to put write-heavy directories (e.g. Downloads) on the hard disk to save on wear on the SSD.

I want to find out which programs and/or files are involved in the heaviest disk write load. For example, if I have a large single document which is edited frequently, or if a program frequently creates and deletes many small files into a directly (e.g. a cache).

I use Ubuntu. I know about iotop, but that's not what I need since AFAIK it only reports activity at the process/device level rather than the application/file level, and it doesn't keep cumulative statistics across reboots.

Is there anything which does this?

1 Answer 1

2

For low level: (sudo) blktrace -d /dev/sda -o - | blkparse -i -

For high level: atop. It gather stats every 10 min (default) and save them to disk. You can browse results later with atop -r /var/log/atop/atop_file (t/T to move forward/back).

2
  • atop looks good but when I run it, it starts with statistics since boot but then a few seconds later this is replaced with more recent data. How can I make it stay on the since-boot data? Thanks
    – spraff
    Commented Jan 14, 2015 at 10:58
  • 1
    Use 'z' key to freeze screen. And atop -r allows to crawl around in the history (including state before reboot). Commented Jan 14, 2015 at 16:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .