Mar 10

简单磁盘性能测试 不指定

felix021 @ 2018-3-10 20:39 [IT » 硬件] 评论(0) , 引用(0) , 阅读(9613) | Via 本站原创 | |
引用
$ sudo apt-get install fio

# 如下命令会创建一个 512M 的文件,测试 64 线程的 4KB 随机读写,75%读,25%写。
# readwrite=randrw表示测试时混合随机读取和随机写入请求,rwmixread指定读请求的占比
$ fio --randrepeat=1 --ioengine=libaio --direct=1 --gtod_reduce=1 --name=test --filename=test --bs=4k --iodepth=64 --size=512M --readwrite=randrw --rwmixread=75

test: (g=0): rw=randrw, bs=4K-4K/4K-4K/4K-4K, ioengine=libaio, iodepth=64
fio-2.2.10
Starting 1 process
test: Laying out IO file(s) (1 file(s) / 512MB)
Jobs: 1 (f=1): [m(1)] [100.0% done] [9268KB/3280KB/0KB /s] [2317/820/0 iops] [eta 00m:00s]
test: (groupid=0, jobs=1): err= 0: pid=13468: Sat Mar 10 19:48:40 2018
  read : io=392888KB, bw=9620.5KB/s, iops=2405, runt= 40839msec
  write: io=131400KB, bw=3217.6KB/s, iops=804, runt= 40839msec
  cpu          : usr=0.54%, sys=1.87%, ctx=32291, majf=0, minf=9
  IO depths    : 1=0.1%, 2=0.1%, 4=0.1%, 8=0.1%, 16=0.1%, 32=0.1%, >=64=100.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.0%, 32=0.0%, 64=0.1%, >=64=0.0%
    issued    : total=r=98222/w=32850/d=0, short=r=0/w=0/d=0, drop=r=0/w=0/d=0
    latency  : target=0, window=0, percentile=100.00%, depth=64

Run status group 0 (all jobs):
  READ: io=392888KB, aggrb=9620KB/s, minb=9620KB/s, maxb=9620KB/s, mint=40839msec, maxt=40839msec
  WRITE: io=131400KB, aggrb=3217KB/s, minb=3217KB/s, maxb=3217KB/s, mint=40839msec, maxt=40839msec

Disk stats (read/write):
  xvdb: ios=98056/32790, merge=0/6, ticks=923380/318272, in_queue=1241828, util=99.83%


这是一个 aws上 的 1000GB EBS 的测试报告,按照 3 IOPS/GB 计算应该能有 3000 的 IOPS,可以看到确实达到了 aws 宣称的性能水平。

参考文章:https://www.binarylane.com.au/support/solutions/articles/1000055889-how-to-benchmark-disk-i-o



欢迎扫码关注:




转载请注明出自 ,如是转载文则注明原出处,谢谢:)
RSS订阅地址: https://www.felix021.com/blog/feed.php
发表评论
表情
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
打开HTML
打开UBB
打开表情
隐藏
记住我
昵称   密码   *非必须
网址   电邮   [注册]