iostat详情
iostat(选项)(参数)
选项
-c:仅显示CPU使用情况 -d:仅显示设备利用率 -k:显示状态以千字节每秒为单位,而不使用块每秒 -m:显示状态以兆字节每秒为单位 -p:仅显示块设备和所有被使用的其他分区的状态 -t:显示每个报告产生时的时间 -V:显示版号并退出 -x:显示扩展状态
参数
间隔时间:每次报告的间隔时间(秒) 次数:显示报告的次数
解释
xxxxxxxxxx[root@localhost conf.d]# iostat -dkx 1 100Linux 3.10.0-957.el7.x86_64 (localhost.localdomain) 06/22/2020 _x86_64_ (8 CPU)
Device: rrqm/s wrqm/s r/s w/s rkB/s wkB/s avgrq-sz avgqu-sz await r_await w_await svctm %utilsda 0.00 0.03 0.03 0.07 2.90 6.21 183.19 0.00 14.72 10.71 16.82 0.28 0.00dm-0 0.00 0.00 0.03 0.09 2.90 6.21 143.15 0.00 23.18 10.86 27.64 0.22 0.00dm-1 0.00 0.00 0.00 0.00 0.00 0.00 11.22 0.00 0.45 0.30 0.51 0.24 0.00以上各列的含义如下:
xxxxxxxxxxrrqm/s The number of read requests merged per second that were queued to the device. wrqm/s The number of write requests merged per second that were queued to the device. r/s The number (after merges) of read requests completed per second for the device. w/s The number (after merges) of write requests completed per second for the device. rsec/s (rkB/s, rMB/s) The number of sectors (kilobytes, megabytes) read from the device per second.wsec/s (wkB/s, wMB/s) The number of sectors (kilobytes, megabytes) written to the device per second. avgrq-sz The average size (in sectors) of the requests that were issued to the device. avgqu-sz The average queue length of the requests that were issued to the device.
await The average time (in milliseconds) for I/O requests issued to the device to be served. This includes the time spent by the requests in queue and the time spent servicing them.
r_await The average time (in milliseconds) for read requests issued to the device to be served. This includes the time spent by the requests in queue and the time spent servicing them.
w_await The average time (in milliseconds) for write requests issued to the device to be served. This includes the time spent by the requests in queue and the time spent servicing them.
svctm The average service time (in milliseconds) for I/O requests that were issued to the device. Warning! Do not trust this field any more. This field will be removed in a future sysstat version.
%util Percentage of elapsed time during which I/O requests were issued to the device (bandwidth utilization for the device). Device saturation occurs when this value is close to 100%.
rrqm/s:
每秒需要读取需求的数量 每秒对该设备的读请求被合并次数,文件系统会对读取同块(block)的请求进行合并
wrqm/s
每秒需要写入需求的数量 每秒对该设备的写请求被合并次数
r/s
每秒实际读取需求的数量
w/s
每秒实际写入需求的数量
rkB/s
xxxxxxxxxx每秒读数据量(kB为单位)
wkB/s
xxxxxxxxxx每秒写数据量(kB为单位)
avgrq-sz
xxxxxxxxxx平均每次IO操作的数据量(扇区数为单位)
avgqu-sz
xxxxxxxxxx平均等待处理的IO请求队列长度
await
xxxxxxxxxx平均每次IO请求等待时间(包括等待时间和处理时间,毫秒为单位)
svctm
xxxxxxxxxx平均每次IO请求的处理时间(毫秒为单位)
%util
xxxxxxxxxx被I/O需求消耗的CPU百分比
重点关注参数
1、iowait% 表示CPU等待IO时间占整个CPU周期的百分比,如果iowait值超过50%,或者明显大于%system、%user以及%idle,表示IO可能存在问题.
2、avgqu-sz 表示磁盘IO队列长度,即IO等待个数。
3、await 表示每次IO请求等待时间,包括等待时间和处理时间
4、svctm 表示每次IO请求处理的时间
5、%util 表示磁盘忙碌情况,一般该值超过80%表示该磁盘可能处于繁忙状态。
评论
发表评论