fabic974 random (binary) wanderings in the philament empires…

iostats

Best option for obtaining I/O statistics is iotop :

$ sudo iotop -oP -d3

But Linux dist. does not have it (?), resort to iostats – This will output some I/O statistics (at most one terminal screen) :

$ iostat -cdkx 2 $(($LINES/6))

Output through watch yields slightly strange results :

$ S_COLORS=always watch -c -n1 iostat -cdkx 1 8

In a loop :

$ while true; do iostat -cdkx 2 $(($LINES/6)); clear; done

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
          30.80    0.32    5.97    0.22    0.00   62.70

Device            r/s     w/s     rkB/s     wkB/s   rrqm/s   wrqm/s  %rrqm  %wrqm r_await w_await aqu-sz rareq-sz wareq-sz  svctm  %util
sda              2.59    1.80    137.88    114.07     0.40     3.09  13.32  63.21    0.82   12.31   0.02    53.30    63.37   0.52   0.23
sdb              0.00    0.08      0.00     33.35     0.00     0.16   4.77  67.12   65.94  370.49   0.03     5.77   428.41   4.80   0.04

TODO: Write down some notes about these numbers (e.g. average queue length).