将设为首页浏览此站
开启辅助访问 天气与日历 收藏本站联系我们切换到窄版

易陆发现论坛

 找回密码
 开始注册
查看: 79|回复: 7
收起左侧

fio测试IO工具

[复制链接]
发表于 2022-6-20 11:37:25 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有帐号?开始注册

x
fio测试IO工具

/ d9 d9 B1 t: g) v$ `. x, r( @
下载地址:
$ H' f8 q: x, z) g2 N+ D

$ |: b8 S  I0 Z' I! z' T
7 T6 A0 z7 f  E3 v; M: T/ i

* \1 _6 i6 y" k* b' F4 s, R
6 W4 S. X" V7 c3 q8 P3 l

% ~; i: z  r; F
fio-2.1.10.tar.gz

: Z! }& E% L& l, N% C2 f3 V

fio-2.1.10.tar.gz

494.75 KB, 下载次数: 0

 楼主| 发表于 2022-6-20 11:49:00 | 显示全部楼层
[root@testssd ~]# tar -zxvf fio-2.1.10.tar.gz     解压fio9 G+ X: B$ Q* G! U1 d3 D; h
fio-2.1.10/0 R' n! ^8 Y6 o3 J: r( I6 S$ y
! s( w( y5 s3 f
安装gcc gcc-c++  make ( ~5 S. s+ {4 O* L' H8 O
# yum install -y gcc gcc-c++ make
2 W' }/ e7 H  u# T6 y
 楼主| 发表于 2022-6-20 13:42:09 | 显示全部楼层
[root@test1hhd fio-2.1.10]# ./configure
6 B8 `! e2 ?  d6 WOperating system              Linux- g% {* A; f: f: W" \$ A
CPU                           x86_64; B2 y7 r5 q* I- c8 f
Big endian                    no
8 V$ F2 t$ L! G* eCompiler                      gcc8 P5 J& N' R# D
Cross compile                 no- a8 ~, z& a$ P  e0 v
% h/ E; G9 R' E1 `6 ^7 ^
Wordsize                      64: M* G! ~  Z8 q3 x; s5 K  m
zlib                          no+ h1 h; v* i7 i
Linux AIO support             no
2 ?/ l) K* n& {, t6 IPOSIX AIO support             yes
/ O' B! Q' ^0 K( b4 {) S4 `POSIX AIO support needs -lrt  yes
  j1 e, L: ]8 M. U, GPOSIX AIO fsync               yes
. V3 ~, a. Q: z+ TSolaris AIO support           no* o( Z* @* ?. l4 W& I2 A! {6 l
__sync_fetch_and_add          yes
' G4 Y* L, I# ?  h0 z1 `libverbs                      no
! o6 h) ?! E$ x( g1 @rdmacm                        no
3 n: r& U4 h4 m% g3 b8 E+ F; tLinux fallocate               yes
* u, H% H$ q4 d) y; E  _7 Z  [POSIX fadvise                 yes
' b/ O# S$ B$ O3 sPOSIX fallocate               yes
2 A; G5 T" L1 esched_setaffinity(3 arg)      yes
  {: L6 h+ L3 V; @7 H( V0 _sched_setaffinity(2 arg)      no( P4 Y, T# P  F: m- R
clock_gettime                 yes; j* Q! m/ ^- G* V+ }
CLOCK_MONOTONIC               yes
( [( U7 h" q  m7 @CLOCK_MONOTONIC_PRECISE       no% a( g5 B0 N& K  @  N! i8 f) j
gettimeofday                  yes
: |5 }: d7 Y, X5 t' g! n/ f# }fdatasync                     yes
3 ~8 m7 b5 e! j: hsync_file_range               yes
$ Y  ~% d( w( @* W1 \7 w0 r9 EEXT4 move extent              yes
" w# ~0 B# Q0 t9 i1 B$ NLinux splice(2)               yes  G$ s" m3 R5 x1 b& k: d. R5 K% P
GUASI                         no. |# c1 g. u8 E* ~
Fusion-io atomic engine       no* `! ~5 X3 d! O5 i; k6 C) ?( x
libnuma                       no  T3 {6 k# N9 Y3 P8 r
strsep                        yes
6 N$ n; p& g9 ]0 Z, `strcasestr                    yes
8 V2 |7 R. Q. ]0 ogetopt_long_only()            yes
4 w) ~! ^# I$ h5 l/ E% t2 w9 _% ]1 Xinet_aton                     yes% i. P) V6 ^3 z# R& }% h
socklen_t                     yes
# J/ K/ s0 S  p1 c" O__thread                      yes- C' Q6 L! \. v& q, T3 x* [$ a5 q
gtk 2.18 or higher            no
3 U* b$ Z& s  }RUSAGE_THREAD                 yes
4 v& Q$ b) D( HSCHED_IDLE                    yes
, }1 `- G1 R0 Y% ^* Q; S$ R) a  PTCP_NODELAY                   yes4 j) [/ M6 ~- X/ j/ r# M2 {' X
RLIMIT_MEMLOCK                yes
. A/ p5 v. v6 [) _+ z' _) f4 v- S$ x/ hpwritev/preadv                yes
) Y# y8 X* H7 [. S/ b( e+ t6 H' TIPv6 helpers                  yes
4 j+ r; {7 F4 z9 E; b' o. [( uRados Block Device engine     no! `& F1 N) V3 J; o/ h
setvbuf                       yes* H/ o+ N* `) K& Z. G% R
Gluster API engine            no
2 ~/ c9 b0 i: I# w+ E2 E. {Gluster API use fadvise       no
: x6 A% [* E& l, X& H* E* W" y8 Cs390_z196_facilities          no
 楼主| 发表于 2022-6-20 13:46:01 | 显示全部楼层
[root@test1hhd fio-2.1.10]# make
  D6 {8 W  V6 p: M7 r: X' W6 oFIO_VERSION = fio-2.1.10
7 [7 l  P- F3 c7 L    CC gettime.o
8 B- P7 d; c) G6 z    CC ioengines.o5 s3 `, a5 Q: L
    CC init.o& ]6 C9 i* i2 T9 b4 n1 F
    CC stat.o" e, j( e1 J5 ~1 z
    CC log.o$ E( i1 e2 o: ]/ g; g
    CC time.o) U0 b6 P% L# B- e! V
    CC filesetup.o' X% Z* R: V* h( R0 M8 h6 l
    CC eta.o
5 }3 P$ h- g! r, w    CC verify.o
/ S6 F' Y* c( u) t+ s7 {7 V    CC memory.o3 a$ I) `% U. N1 N, R0 m. y
    CC io_u.o3 E& P% c# s6 p9 }1 {+ g
    CC parse.o
) G9 }# K  ~1 i0 P* x; B    CC mutex.o
* z0 t9 w5 v7 i9 N    CC options.o
8 z7 E& O  J. ]+ v    CC lib/rbtree.o
) h: [: R0 ]8 v$ Q/ z# i. |+ U0 Y    CC smalloc.o7 j2 m, @1 U- m4 L) S" F
    CC filehash.o
) o) I$ t6 g7 m    CC profile.o
7 j% {/ H: u, C. V% n  Z4 v    CC debug.o
: v% t! p5 c1 S  x    CC lib/rand.o$ b/ D( z1 i" i
    CC lib/num2str.o
! [  c$ S. @) D/ @2 j$ }    CC lib/ieee754.o0 s+ y' _4 x. b% H' w
    CC crc/crc16.o3 b  c$ l9 W, M( U4 w
    CC crc/sha512.o
& e6 p( N) b! r3 M; Y( [$ I  p    CC crc/crc7.o
, j" t8 U: ?% Q    CC crc/sha1.o  z' C9 O: _8 z0 p% Y0 H/ S
    CC crc/crc32c.o7 r$ v0 W3 Y1 E. R/ S- I
    CC crc/crc32.o3 h' B9 [4 `) e, G/ S3 i/ V
    CC crc/crc32c-intel.o) ^2 s' e+ C5 F& L6 ^9 K
    CC crc/xxhash.o4 C, i6 C/ V. Q
    CC crc/test.o
: b: k$ N5 S0 n. Z& v* j    CC crc/sha256.o! `1 J& h8 w. n
    CC crc/md5.o9 `" P  S8 e; S- Q
    CC crc/crc64.o
7 {8 T6 e$ _9 H5 W5 @    CC engines/cpu.o  x# t: u+ U# n* B8 B
    CC engines/mmap.o1 Y: W, f/ z0 Z, x. s
    CC engines/sync.o
4 ^# K) A4 E  c" [/ y0 M6 a$ I( j    CC engines/null.o2 J$ t- w, L4 J8 C5 e
    CC engines/net.o  P1 v% F: m. F* ?& L+ |" h- Y
    CC memalign.o- b0 i6 k" f1 t5 g- Z1 m
    CC server.o' `9 B4 b, N1 A- |& c
    CC client.o6 D9 f* X( s, e9 d) n
    CC iolog.o
1 M1 r& ]$ g; o: U0 P5 s3 `    CC backend.o
! I' N" d# b. s$ o# u0 ^5 ^& L( h* N    CC libfio.o! K& H: f) M2 Q/ t
    CC flow.o
- G5 A& o. f% N6 l    CC cconv.o0 T" R) X5 w$ m6 B' Z
    CC lib/prio_tree.o! M3 G! Q2 D$ G
    CC json.o! e$ ?, L9 G4 @; _
    CC lib/zipf.o
2 l" {& b5 t8 u5 w4 c    CC lib/axmap.o7 z4 y4 C2 [( T1 j' m; {# Y* g
    CC lib/lfsr.o
4 N; f4 g  T# W  s% ^    CC gettime-thread.o
5 x# ?0 Q! \6 P! `& w; t  I4 w    CC helpers.o& ^! e/ S  G6 u7 x, q, ~
    CC lib/flist_sort.o* E/ x& Z' b: @" p9 J! G
    CC lib/hweight.o2 R( @# ~8 a9 E0 h, D0 t/ {  `" Q
    CC lib/getrusage.o
4 a7 k2 t- O5 K  Q- a" r    CC idletime.o, U& r. B) L0 h2 s9 A" W! v
    CC td_error.o
6 c- x! c4 Z: \    CC profiles/tiobench.o
% l& L! L5 B7 C6 X7 r    CC profiles/act.o
$ R& g2 Z& A' P% P4 f4 z    CC io_u_queue.o
0 s7 D' ?4 G) J/ c; L' g    CC filelock.o
' f+ K7 w2 X0 u1 c: F    CC engines/posixaio.o
/ F4 W1 V# z# P8 g! L+ Q( D    CC engines/falloc.o4 l+ R  q+ k* l5 _; K2 R0 i- y
    CC engines/e4defrag.o( E4 A: c2 h5 ~1 s5 |! \8 F
    CC engines/splice.o- A/ S4 j5 s/ e& w
    CC diskutil.o+ ?* U5 \! V5 F; j0 T
    CC fifo.o1 l0 g$ `- }- ^
    CC blktrace.o
& T, ?2 k2 K5 K2 K* M% M' X    CC cgroup.o$ a+ b1 A0 A) F; p$ Y: L2 D+ \' j
    CC trim.o5 @; \2 u' N9 E; k) a! \& l- P
    CC engines/sg.o# X1 P4 n& Q1 i9 ]( d
    CC engines/binject.o
2 k% Y) S/ s( f5 J3 J: H    CC fio.o% g. P+ A. L' p5 d' N
    LINK fio0 {! l. {1 W" Y. N1 r5 y% @8 P- R
[root@test1hhd fio-2.1.10]#  make install
. f! \: s+ J9 `install -m 755 -d /usr/local/bin
: I( H: L. N7 A! W9 f( ~5 ainstall fio tools/fio_generate_plots tools/plot/fio2gnuplot tools/genfio /usr/local/bin
/ O! i3 M+ t& M2 ?* ]( r! W  w8 m( n* binstall -m 755 -d /usr/local/man/man11 B- a+ d% W( h9 @$ i9 {: R
install -m 644 fio.1 /usr/local/man/man1
0 ~; L2 Q/ G* p5 Yinstall -m 644 tools/fio_generate_plots.1 /usr/local/man/man17 _) y& I/ B- b
install -m 644 tools/plot/fio2gnuplot.1 /usr/local/man/man1
! y( r$ l5 W. d4 X# kinstall -m 755 -d /usr/local/share/fio
8 |- s/ W: U- Y( `, g# Rinstall -m 644 tools/plot/*gpm /usr/local/share/fio/
 楼主| 发表于 2022-6-20 13:51:38 | 显示全部楼层
[root@test1hhd ~]# fio -filename=/dev/vda  -direct=1 -iodepth 1 -thread -rw=randread -ioengine=psync -bs=4k -size=1000G -numjobs=50 -runtime=180 -group_reporting -name=rand_100read_4k
% h; W0 z0 Z' k! R# C  c+ f) w& Frand_100read_4k: (g=0): rw=randread, bs=4K-4K/4K-4K/4K-4K, ioengine=psync, iodepth=13 P7 p, v9 b1 g8 B7 u4 n) g* M
...
2 y' E" V  I) C2 d1 P% H6 ]fio-2.1.10- @( Z2 N5 L3 _3 J
Starting 50 threads/ f" V  h* c) l; ~6 T
Jobs: 50 (f=50): [rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr] [11.0% done] [12671KB/0KB/0KB /s] [3167/0/0 iops] [eta 02m:41sJobs: 50 (f=50): [rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr] [11.6% done] [14601KB/0KB/0KB /s] [3650/0/0 iops] [eta 02m:40sJobs: 50 (f=50): [rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr] [12.2% done] [7948KB/0KB/0KB /s] [1987/0/0 iops] [eta 02m:39s]Jobs: 6 (f=6): [___rr___r_________________r__________________r___r] [2.2% done] [163KB/0KB/0KB /s] [40/0/0 iops] [eta 02h:12m:01s]] - C8 M9 R  W  S
rand_100read_4k: (groupid=0, jobs=50): err= 0: pid=19880: Mon Jun 20 13:42:03 2022
8 d5 F  u) A# c1 ~- [3 }  read : io=840436KB, bw=4634.1KB/s, iops=1158, runt=181327msec
' ~3 }3 V. A$ q( Z4 K    clat (usec): min=308, max=3703.3K, avg=42907.91, stdev=175774.03
% q$ W$ e: S2 c7 ^3 {: M# j     lat (usec): min=308, max=3703.3K, avg=42908.22, stdev=175774.045 s5 L7 R7 N$ w+ V
    clat percentiles (usec):1 J2 _6 `4 z) Y2 i& j3 `% E
     |  1.00th=[  402],  5.00th=[  450], 10.00th=[  482], 20.00th=[  532],% a. s8 g2 z5 s2 Q
     | 30.00th=[  572], 40.00th=[  612], 50.00th=[  684], 60.00th=[ 1688],
$ s2 _2 f4 N1 Q; E     | 70.00th=[ 7776], 80.00th=[30848], 90.00th=[93696], 95.00th=[195584],( x' ^2 j( F# d1 t2 Q& t
     | 99.00th=[700416], 99.50th=[1335296], 99.90th=[2473984], 99.95th=[2867200],
. y; o( D% \$ s     | 99.99th=[3293184]
- v( i) ^& J& d/ a    bw (KB  /s): min=    1, max=  810, per=2.59%, avg=119.98, stdev=103.340 K$ t7 C& w9 b7 b9 B0 W  t
    lat (usec) : 500=13.52%, 750=41.62%, 1000=3.46%
+ d' X3 j$ S6 R! I1 r5 B    lat (msec) : 2=1.79%, 4=4.13%, 10=6.84%, 20=4.77%, 50=8.64%" p8 o) Z8 I. S5 p" k; [" W
    lat (msec) : 100=5.68%, 250=5.93%, 500=2.12%, 750=0.58%, 1000=0.24%
- w5 P# h: Z) N+ b+ t    lat (msec) : 2000=0.49%, >=2000=0.20%
3 W* v& U/ y& ^# h1 Q( q# e8 H  cpu          : usr=0.04%, sys=0.06%, ctx=210142, majf=0, minf=59
% t( n2 v) q4 Y( ~  z  IO depths    : 1=100.0%, 2=0.0%, 4=0.0%, 8=0.0%, 16=0.0%, 32=0.0%, >=64=0.0%$ C5 V- [( a" t- z  a
     submit    : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.0%, 32=0.0%, 64=0.0%, >=64=0.0%6 ~6 H2 g, D$ _3 ^. X7 t
     complete  : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.0%, 32=0.0%, 64=0.0%, >=64=0.0%
! n6 E, I. A: Z     issued    : total=r=210109/w=0/d=0, short=r=0/w=0/d=03 ?) D/ O7 Y% r% V0 c8 V: r
     latency   : target=0, window=0, percentile=100.00%, depth=1
1 O( X/ T! d* d
6 p/ \) e2 k2 |8 Q! U3 `3 O5 V& D5 yRun status group 0 (all jobs):
0 V2 F" c: \( v; \& l, c9 I6 {- [   READ: io=840436KB, aggrb=4634KB/s, minb=4634KB/s, maxb=4634KB/s, mint=181327msec, maxt=181327msec
) h5 U4 T( I% x8 X0 R; x& x3 b/ z6 H6 V% V8 E& C
Disk stats (read/write):
% @$ @6 E' v# |  vda: ios=210103/28, merge=0/2, ticks=8996207/20602, in_queue=8914609, util=98.70%
 楼主| 发表于 2022-6-20 14:13:58 | 显示全部楼层
fio -filename=/dev/vda  -direct=1 -iodepth 1 -thread -rw=randread -ioengine=psync -bs=4k -size=1000G -numjobs=50 -runtime=180 -group_reporting -name=rand_100read_4k
* t3 c! P" }5 o! W) F0 @6 \. B fio -filename=/dev/vda -direct=1 -iodepth 1 -thread -rw=randwrite -ioengine=psync -bs=4k -size=1000G -numjobs=50 -runtime=180 -group_reporting -name=rand_100write_4k% {( U  W: \/ v- ?# S% X

; O2 A# N7 x1 J: U' o( }2 G4 \" F* Jfio -filename=/dev/vda -direct=1 -iodepth 1 -thread -rw=read -ioengine=psync -bs=4k -size=1000G -numjobs=50 -runtime=180 -group_reporting -name=sqe_100read_4k
' ]4 q7 F$ J" X: M8 i6 ?8 w- x7 u" K" ]( B( T3 U
( T5 N  P. g- A8 q3 p) |
测试场景:
  100%随机,100%读, 4K* L* a" a) c/ G1 h4 d+ S0 R6 c
  fio -filename=/dev/vda -direct=1 -iodepth 1 -thread -rw=randread -ioengine=psync -bs=4k -size=1000G -numjobs=50 -runtime=180 -group_reporting -name=rand_100read_4k
  100%随机,100%写, 4K
+ H# ~# |% A! q% ?  fio -filename=/dev/vda -direct=1 -iodepth 1 -thread -rw=randwrite -ioengine=psync -bs=4k -size=1000G -numjobs=50 -runtime=180 -group_reporting -name=rand_100write_4k
  100%顺序,100%读 ,4K
8 t' }, p2 k' \5 ~  fio -filename=/dev/vda -direct=1 -iodepth 1 -thread -rw=read -ioengine=psync -bs=4k -size=1000G -numjobs=50 -runtime=180 -group_reporting -name=sqe_100read_4k
  100%顺序,100%写 ,4K
  b" ]' o- T1 ^  fio -filename=/dev/vda -direct=1 -iodepth 1 -thread -rw=write -ioengine=psync -bs=4k -size=1000G -numjobs=50 -runtime=180 -group_reporting -name=sqe_100write_4k
  100%随机,70%读,30%写 4K
: R- Y8 ]& i. ]1 [9 y% O  fio -filename=/dev/vda -direct=1 -iodepth 1 -thread -rw=randrw -rwmixread=70 -ioengine=psync -bs=4k -size=1000G -numjobs=50 -runtime=180 -group_reporting -name=randrw_70read_4k
 楼主| 发表于 2022-6-20 14:32:51 | 显示全部楼层
[root@testssd ~]# fio -ioengine=libaio -bs=16k -direct=1 -thread -rw=read -size=1G -filename=test.img -name="test" -iodepth=1 -time_based -runtime=60 -numjobs=16 -group_reporting
3 o9 D; Y( ^3 [( u/ T! ]) Hfio: engine libaio not loadable
. O1 [+ a8 J- h) }& Ufio: failed to load engine libaio
+ H( B+ A9 t8 n4 _! w# [[root@testssd ~]# fio -filename=/dev/vda -ioengine=libaio -bs=16k -direct=1 -thread -rw=read -size=1G -filename=test.img -name="test" -iodepth=1 -time_based -runtime=60 -numjobs=16 -group_reporting
# w  y: k& q1 t1 {fio: engine libaio not loadable) T1 G5 L5 E' W4 c) m  {. G
fio: failed to load engine libaio
7 F# M! s/ R' O* T4 E[root@testssd ~]# fio -filename=/dev/vda  -bs=16k -direct=1 -thread -rw=read -size=1G -filename=test.img -name="test" -iodepth=1 -time_based -runtime=60 -numjobs=16 -group_reporting9 R9 x& R# Q5 f1 j  e% r
test: (g=0): rw=read, bs=16K-16K/16K-16K/16K-16K, ioengine=sync, iodepth=1
1 t$ Q" J" d8 ^" y...& j: l9 x+ Z0 j' D  ~
fio-2.1.10
5 d) t$ U1 h( @- y# \: L/ u. {Starting 16 threads
0 f1 Y5 p5 V% g/ {5 A1 G" M, }5 H5 M4 jtest: Laying out IO file(s) (1 file(s) / 512MB)0 [6 h5 p! c/ n9 K# |
Jobs: 16 (f=32): [RRRRRRRRRRRRRRRR] [100.0% done] [141.7MB/0KB/0KB /s] [9027/0/0 iops] [eta 00m:00s]' L# T1 l5 Q' O
test: (groupid=0, jobs=16): err= 0: pid=21845: Mon Jun 20 14:19:25 2022+ b. a# S  g% c; u
  read : io=8328.9MB, bw=142137KB/s, iops=8883, runt= 60004msec
- E8 t% @. _. C6 e    clat (usec): min=215, max=62700, avg=1798.77, stdev=1583.64
8 m0 k* h) E( l* S+ o4 O  `4 x1 q     lat (usec): min=215, max=62700, avg=1798.97, stdev=1583.658 p* ~4 z" c! \6 H
    clat percentiles (usec):
* a' W: S9 S, X6 N4 C7 ~% X     |  1.00th=[  306],  5.00th=[  362], 10.00th=[  458], 20.00th=[  724],) e# i0 p4 e5 \. S6 P' _" c
     | 30.00th=[ 1096], 40.00th=[ 1640], 50.00th=[ 1864], 60.00th=[ 2024],
3 J  U. B, S8 i: H' j4 j0 s     | 70.00th=[ 2224], 80.00th=[ 2320], 90.00th=[ 2608], 95.00th=[ 2928],
! E$ l. n- E. e2 O8 U! Y1 Z     | 99.00th=[ 6944], 99.50th=[10432], 99.90th=[22656], 99.95th=[26240],+ m6 G& ^7 n: S7 i
     | 99.99th=[34560]
5 C0 n# Z. t' I8 X5 o    bw (KB  /s): min= 2331, max=19523, per=6.25%, avg=8879.79, stdev=3417.38. N) ?! G. F, o+ r9 n* l! y' {/ ]
    lat (usec) : 250=0.01%, 500=11.32%, 750=9.70%, 1000=7.54%
! B+ w; |) C  d# w# \    lat (msec) : 2=30.34%, 4=39.02%, 10=1.53%, 20=0.39%, 50=0.14%
" j) q6 ?8 e& p# P3 I# ~* r6 S    lat (msec) : 100=0.01%
0 M& T% i3 V2 |% G  cpu          : usr=0.29%, sys=1.34%, ctx=533068, majf=0, minf=82
  g" G' k# s0 ]. P$ \  IO depths    : 1=100.0%, 2=0.0%, 4=0.0%, 8=0.0%, 16=0.0%, 32=0.0%, >=64=0.0%3 f0 N! V* ^7 e$ F+ ?
     submit    : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.0%, 32=0.0%, 64=0.0%, >=64=0.0%7 {9 r8 Y% Z/ ]2 g( ^3 S. q
     complete  : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.0%, 32=0.0%, 64=0.0%, >=64=0.0%4 `. t% V( t) t: e# y
     issued    : total=r=533048/w=0/d=0, short=r=0/w=0/d=0
- \+ x+ y/ i0 s9 Q+ R9 q     latency   : target=0, window=0, percentile=100.00%, depth=1# A  Z, e3 x) L& K) Z4 F* P
& J; I- K/ ]- n: y
Run status group 0 (all jobs):" r* h" I7 ?) M+ a! u- G
   READ: io=8328.9MB, aggrb=142136KB/s, minb=142136KB/s, maxb=142136KB/s, mint=60004msec, maxt=60004msec
4 K& u9 E7 ]8 p* ^8 {/ M5 z- f- S2 Q: w  l+ G" E
Disk stats (read/write):# @" Z7 @6 g4 e8 Z8 f+ G
  vda: ios=529229/11, merge=784/1, ticks=938227/67, in_queue=936843, util=99.83%2 z8 w+ c- X5 Q  B) R
  dm-0: ios=265320/10, merge=0/0, ticks=475542/77, in_queue=476458, util=98.64%
9 d$ n6 Q% g1 m5 J, C' o% [[root@testssd ~]# fio   -bs=16k -direct=1 -thread -rw=read -size=1G -filename=test.img -name="test" -iodepth=1 -time_based -runtime=60 -numjobs=16 -group_reporting
, b2 G4 r! m) w/ btest: (g=0): rw=read, bs=16K-16K/16K-16K/16K-16K, ioengine=sync, iodepth=12 `" H# }2 j9 y
.... U* S- w2 U& @! B% x' d
fio-2.1.10
. W% a2 l( ?, v" pStarting 16 threads/ n/ I7 c: a0 Y1 m) b( @
test: Laying out IO file(s) (1 file(s) / 1024MB)- t* ?) E2 I: }4 t4 V- B
Jobs: 16 (f=16): [RRRRRRRRRRRRRRRR] [100.0% done] [139.3MB/0KB/0KB /s] [8914/0/0 iops] [eta 00m:00s]7 H. v) t- X: |' _) i7 |" S& J
test: (groupid=0, jobs=16): err= 0: pid=21868: Mon Jun 20 14:23:39 2022
0 J# ?3 |) o  @  read : io=8815.7MB, bw=150436KB/s, iops=9402, runt= 60003msec
9 O: Z* a6 V; u( `# d    clat (usec): min=255, max=44491, avg=1695.99, stdev=1232.95% w, s$ ?& L0 d( j+ C+ ^
     lat (usec): min=255, max=44492, avg=1696.20, stdev=1232.95
& {9 T  t* l$ P" n    clat percentiles (usec):; f+ ?8 b/ y" J+ V# }9 L
     |  1.00th=[  426],  5.00th=[  532], 10.00th=[  636], 20.00th=[  820],8 @# B3 t- S: F9 a
     | 30.00th=[  948], 40.00th=[ 1176], 50.00th=[ 1688], 60.00th=[ 2192],
) l, w( \  Z  f     | 70.00th=[ 2256], 80.00th=[ 2288], 90.00th=[ 2448], 95.00th=[ 2832],
( ]1 v( ^" B" @% H5 [! w- G1 I     | 99.00th=[ 4960], 99.50th=[ 7968], 99.90th=[15808], 99.95th=[21120],
$ J% T8 ?' J# E# Y3 n, M, [% `     | 99.99th=[31360]3 _# I9 K: j$ }  ^0 ^5 y6 a
    bw (KB  /s): min= 3937, max=24768, per=6.26%, avg=9414.93, stdev=3580.204 F4 V$ y# B/ B/ }( y1 K
    lat (usec) : 500=3.42%, 750=12.21%, 1000=17.97%
) C8 ?5 V/ v2 l+ O    lat (msec) : 2=21.95%, 4=43.18%, 10=0.98%, 20=0.22%, 50=0.06%' [0 N/ d2 V( T# h
  cpu          : usr=0.28%, sys=1.52%, ctx=564232, majf=0, minf=82
$ `' s7 M3 }5 B3 _9 t# W7 i; }# f  IO depths    : 1=100.0%, 2=0.0%, 4=0.0%, 8=0.0%, 16=0.0%, 32=0.0%, >=64=0.0%
, q8 V+ P5 B6 p     submit    : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.0%, 32=0.0%, 64=0.0%, >=64=0.0%
! c! Y: X  H' T4 T" q- w, O# [     complete  : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.0%, 32=0.0%, 64=0.0%, >=64=0.0%
. V8 d2 u3 B  B& l+ c     issued    : total=r=564164/w=0/d=0, short=r=0/w=0/d=0/ i: ]' `' }. b8 j; m& r
     latency   : target=0, window=0, percentile=100.00%, depth=17 k- m& R! A& F$ E; Z
" B" z( o; P  D( a
Run status group 0 (all jobs):$ Q( Q* j$ a$ o: E" N+ O
   READ: io=8815.7MB, aggrb=150436KB/s, minb=150436KB/s, maxb=150436KB/s, mint=60003msec, maxt=60003msec
: S" S+ o) _6 f8 `2 W
5 j2 m# U6 y/ K/ n  k' v$ {Disk stats (read/write):
2 i: |" R0 |5 k. g5 f    dm-0: ios=563996/9, merge=0/0, ticks=941286/41, in_queue=942042, util=99.74%, aggrios=562960/10, aggrmerge=899/1, aggrticks=939104/36, aggrin_queue=938630, aggrutil=99.65%
0 b5 i) Z6 Q- ~5 ^, R6 X$ t; M  vda: ios=562960/10, merge=899/1, ticks=939104/36, in_queue=938630, util=99.65%3 ]7 A$ L7 O" K  ^
[root@testssd ~]#
 楼主| 发表于 4 天前 | 显示全部楼层
测试延迟4 R! B) k5 S) O" `: M+ j
; L& P9 C5 F( K+ |1 [0 d- g
​ 队列深度为1,bs设置为4k,也就是模拟单个队列读写的延迟测试
8 U5 x/ u% c( T; _/ ?! _. h: G; }* J$ r( E, O1 e6 h
吞吐6 f, h( r$ {+ k+ \& n# d
* h0 V0 ]# v; x2 y7 p* Z* _
​ 队列深度为32,bs设置为128k,测试最大能力去跑满整个磁盘带宽( D( n6 A- W4 @* ^0 S% }+ o

7 P" M0 n7 [. e5 d1 Q" Yiops
" ^2 f: X- ~" k" w: `3 M2 s# j* d4 V9 g! o5 o
​ 队列深度为32,bs设置为4k,要在最短的时间内多去读磁盘$ \1 {" m( `# y, G' N* [$ t, m
/ ~/ V$ U# A. p; I
小文件通常测试随机读写,大文件通常测试顺序读写。2 N/ `0 I) g0 T/ \/ A  h8 L

' R& I$ g7 T6 B( F. C& y测试顺序读IOPS
1 U( p% F& Z/ O- o. c2 I% O( ?
, U9 C4 i2 w2 G( Qfio -name=Seq_Read_IOPS_Test -group_reporting -direct=1 -iodepth=128 -rw=read -ioengine=libaio -refill_buffers -norandommap -randrepeat=0 -bs=4k -size=10G -numjobs=1 -runtime=600 -filename=/dev/[device] # ~5 C7 z4 E! H, R
测试顺序写IOPS
( J& y% O! h( N
4 d$ ^# Y4 O3 ^8 r7 Y% n- O  Ffio -name=Seq_Write_IOPS_Test -group_reporting  -direct=1 -iodepth=128 -rw=write -ioengine=libaio -refill_buffers -norandommap -randrepeat=0 -bs=4k -size=10G -numjobs=1 -runtime=600 -filename=/dev/[device] ( R1 L, C. n# G6 j7 W
测试随机写IOPS
& H" e) m) g1 N% u) U( S. U
  c( M1 i/ a$ {# u" J. u4 c! G( Lfio -name=Rand_Write_IOPS_Test -group_reporting -direct=1 -iodepth=128 -rw=randwrite -ioengine=libaio -refill_buffers -norandommap -randrepeat=0 -bs=4k -size=10G -numjobs=1 -runtime=600 -filename=/dev/[device]
6 v7 ~/ n, A9 E2 h测试随机读IOPS) K: Z9 W$ m; O1 P

/ R6 {0 h8 [* ]0 Mfio -name=Rand_Read_IOPS_Test -group_reporting -direct=1 -iodepth=128 -rw=randread -ioengine=libaio -refill_buffers -norandommap -randrepeat=0 -bs=4k -size=10G -numjobs=1 -runtime=600 -filename=/dev/[device]
5 \% Q7 W6 P* O( p. V' S测试混合读写
  _8 O& [. j1 V8 l4 Z" N* `% P
. n7 H3 o( r  i" }: u4 b+ Tfio -name=Read_Write_IOPS_Test -group_reporting -direct=1 -iodepth=128 -rw=randrw -rwmixread=70 -refill_buffers -norandommap -randrepeat=0 -ioengine=libaio -bs=4k -size=10G -numjobs=1 -runtime=600 -ioscheduler=noop3 g; d( z  Q" F! U7 x1 c
测试写吞吐量
# c! T2 k; u. E) G* b. l3 i4 C* d, S% q  r; Q3 b; \
fio -name=Write_BandWidth_Test -group_reporting -direct=1 -iodepth=32 -rw=write -ioengine=libaio -refill_buffers -norandommap -randrepeat=0 -bs=1024k -size=10G -numjobs=1 -runtime=600 -filename=/dev/[device]
) Q$ e6 \9 N# Q/ s测试读吞吐量3 f  i0 ~( H  @5 F0 }$ O

$ K* o' Y9 F& J' L. O3 ~fio -name=Read_BandWidth_Test -group_reporting -direct=1 -iodepth=32 -rw=read -ioengine=libaio -refill_buffers -norandommap -randrepeat=0 -bs=1024k -size=10G -numjobs=1 -runtime=600 -filename=/dev/[device] 0 {7 r! q" p: N! S  w
测试结果输出指标
& r6 f3 v! D$ E, ]) Y: w4 ^IOPS:每秒读/写次数,单位为次(计数)。存储设备的底层驱动类型决定了不同的 IOPS。 --> iops" L6 I" a, Z7 b0 m* t4 e% r
吞吐量:每秒的读写数据量,单位为MB/s。 --> bw
9 B$ q8 [" Q9 S时延:I/O 操作的发送时间到接收确认所经过的时间,单位为秒。 --> lat (msec)9 L: |" ^- v# E# z$ N2 k
runt:总运行时间
您需要登录后才可以回帖 登录 | 开始注册

本版积分规则

关闭

站长推荐上一条 /4 下一条

如有购买积分卡请联系497906712

QQ|返回首页|Archiver|手机版|小黑屋|易陆发现 点击这里给我发消息

GMT+8, 2022-7-4 11:47 , Processed in 0.052169 second(s), 26 queries .

Powered by LR.LINUX.cloud bbs168x X3.2 Licensed

© 2012-2022 Comsenz Inc.

快速回复 返回顶部 返回列表