
procfs-diskstatsの結果を解釈する方法に興味があります。 APIのように見えますが、インターネット、マニュアルページ、またはLinuxカーネルのドキュメントで詳細な説明を見たことはありません。
一つある文書非常に簡潔な説明があります。
The /proc/diskstats file displays the I/O statistics
of block devices. Each line contains the following 14
fields:
== ===================================
1 major number
2 minor mumber
3 device name
4 reads completed successfully
5 reads merged
6 sectors read
7 time spent reading (ms)
8 writes completed
9 writes merged
10 sectors written
11 time spent writing (ms)
12 I/Os currently in progress
13 time spent doing I/Os (ms)
14 weighted time spent doing I/Os (ms)
== ===================================
...
そしてiostats.rstいくつかの言葉を教えてください。しかし、この指標が正確に何を意味するのかはまだ難しいです。
13 time spent doing I/Os (ms)
iostats.rstから:
Field 10 -- # of milliseconds spent doing I/Os (unsigned int)
This field increases so long as field 9 is nonzero.
Since 5.0 this field counts jiffies when at least one request was
started or completed. If request runs more than 2 jiffies then some
I/O time might be not accounted in case of concurrent requests.
しかし、この値を見ると毎秒私の4コアCPU VMで値が増加します(デルタ)。100000ミリ秒以上fe 4Gbファイルをコピーする場合。
私は推測できるHDD/SSD(SATA?バスによって異なりますか?)複数のCPUコア要求を並列に処理できます。。
4コアCPUでは、これはこのカウンタの100000ミリ秒の増加が1秒あたりのHDD / SDDサービス(CPUコアあたり少なくとも25秒の要求)を示すことを意味します。または、2つのコアで50秒(1秒あたり)、または1つのコアで100秒(1秒あたり)です。
常識的には、毎秒1秒以上の操作を実行することはできません。
関連投稿:/proc/diskstats ディスク読み取り時間が 1 秒あたり 1 秒以上増加します。
UPD:Linuxカーネル4.4.161、x86_64