参考文档:
https://www.cnblogs.com/yuhaohao/p/9770701.html
命令:
fio --filename=/mnt/test_rw --bs=16K --rw=randwrite --size=20G --runtime=300 --time_based --ioengine=libaio --iodepth=16 --numjobs=2 --group_reporting --name=test --direct=1
结果:
test: (g=0): rw=randwrite, bs=16K-16K/16K-16K/16K-16K, ioengine=libaio, iodepth=16
test: (g=0): rw=randwrite, bs=16K-16K/16K-16K/16K-16K, ioengine=libaio, iodepth=16
fio-2.0.13
Starting 2 processes
Jobs: 2 (f=2): [ww] [100.0% done] [0K/329.9M/0K /s] [0 /21.2K/0 iops] [eta 00m:00s]
test: (groupid=0, jobs=2): err= 0: pid=26607: Tue May 26 13:57:43 2020
write: io=96641MB, bw=329867KB/s, iops=20616 , runt=300002msec
slat (usec): min=2 , max=4536 , avg=16.88, stdev=14.18
clat (usec): min=167 , max=35953 , avg=1533.67, stdev=650.85
lat (usec): min=482 , max=35960 , avg=1550.75, stdev=651.10
clat percentiles (usec):
| 1.00th=[ 828], 5.00th=[ 988], 10.00th=[ 1080], 20.00th=[ 1192],
| 30.00th=[ 1272], 40.00th=[ 1352], 50.00th=[ 1432], 60.00th=[ 1512],
| 70.00th=[ 1592], 80.00th=[ 1720], 90.00th=[ 1928], 95.00th=[ 2480],
| 99.00th=[ 3888], 99.50th=[ 4256], 99.90th=[ 7328], 99.95th=[10560],
| 99.99th=[19328]
bw (KB/s) : min=76391, max=204384, per=50.02%, avg=165010.80, stdev=19838.58
lat (usec) : 250=0.01%, 500=0.01%, 750=0.32%, 1000=5.37%
lat (msec) : 2=85.75%, 4=7.73%, 10=0.77%, 20=0.05%, 50=0.01%
cpu : usr=4.33%, sys=18.68%, ctx=2061086, majf=0, minf=48
IO depths : 1=0.1%, 2=0.1%, 4=0.1%, 8=0.1%, 16=100.0%, 32=0.0%, >=64=0.0%
submit : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.0%, 32=0.0%, 64=0.0%, >=64=0.0%
complete : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.1%, 32=0.0%, 64=0.0%, >=64=0.0%
issued : total=r=0/w=6185042/d=0, short=r=0/w=0/d=0
Run status group 0 (all jobs):
WRITE: io=96641MB, aggrb=329866KB/s, minb=329866KB/s, maxb=329866KB/s, mint=300002msec, maxt=300002msec
Disk stats (read/write):
sda: ios=147/6182972, merge=0/1612, ticks=265/9459214, in_queue=9458539, util=100.00%