Is there a good command line utility
to monitor hard disk load on linux? Something like top
but then
monitoring disk activity i.s.o. cpu
usage.
More specifically, I suspect
that for some (heavy load) servers after several optimizations on various parts of the
program(s) that run on it, right now the bottleneck is simply the logging to files on
the disk. But I find it very difficult to assess how much traffic the servers can
handle.
My ideal tool would be something that
prints "You're using 35% of your disk bandwidth right now". Any
ideas?
Answer
You can get a pretty good measure of this
using the iostat
tool.
% iostat -dx /dev/sda
5
Device: rrqm/s wrqm/s r/s w/s rsec/s wsec/s avgrq-sz avgqu-sz
await svctm %util
sda 0.78 11.03 1.19 2.82 72.98 111.07 45.80 0.13 32.78 1.60
0.64
The
disk utilisation is listed in the last column. This is defined
as
Percentage of
CPU time during which I/O requests were issued to the device
(band-width
utilization for the device). Device saturation
occurs when this value is
close to 100%.
Comments
Post a Comment