Monitoring disk block access in Linux
- by VoidPointer
Is there a way to gather statistics about blocks being accessed on a disk?
I have a scenario where a task is both memory and I/O intensive and I need to find a good balance as to how much of the available RAM I can assign to the process and how much I should leave for the system for building its I/O cache for the block device being used.
I suspect that most of the I/O that is currently happening is accessing a rather small subset of the device and that performance could be optimized by increasing the RAM that is available for I/O buffering.
Ideally, I would be able to create something like a "heat-map" that shows me which parts of the disk are accessed most of the time.