備忘としてメモ。
デフォルトではクライアント→サーバー方向のスループットが計測される。が結論。
-rオプションでサーバー→クライアント方向のスループットも計測できる。
サーバー側(172.11.4.110)
[root@ip-172-11-4-110 ~]# iperf -s
------------------------------------------------------------
Server listening on TCP port 5001
TCP window size: 85.3 KByte (default)
------------------------------------------------------------
[ 4] local 172.11.4.110 port 5001 connected with 172.11.4.85 port 49136
[ ID] Interval Transfer Bandwidth
[ 4] 0.0-10.0 sec 1.17 GBytes 1.00 Gbits/sec
------------------------------------------------------------
Client connecting to 172.11.4.85, TCP port 5001
TCP window size: 444 KByte (default)
------------------------------------------------------------
[ 4] local 172.11.4.110 port 33607 connected with 172.11.4.85 port 5001
[ 4] 0.0-10.0 sec 1.16 GBytes 998 Mbits/sec
クライアント側(172.11.4.85)
[root@ip-172-11-4-85 ~]# iperf -c 172.11.4.110 -r
------------------------------------------------------------
Server listening on TCP port 5001
TCP window size: 85.3 KByte (default)
------------------------------------------------------------
------------------------------------------------------------
Client connecting to 172.11.4.110, TCP port 5001
TCP window size: 481 KByte (default)
------------------------------------------------------------
[ 3] local 172.11.4.85 port 49136 connected with 172.11.4.110 port 5001
[ ID] Interval Transfer Bandwidth
[ 3] 0.0-10.0 sec 1.17 GBytes 1.01 Gbits/sec
[ 5] local 172.11.4.85 port 5001 connected with 172.11.4.110 port 33607
[ 5] 0.0-10.0 sec 1.16 GBytes 997 Mbits/sec
サーバー側でのトラフィック推移(dstat)
[root@ip-172-11-4-110 ~]# dstat -n
-net/total-
recv send
(略)
52B 154B
1552B 208B
52B 154B
104B 260B
52B 154B
68M 284k
122M 497k
119M 492k
121M 499k
120M 493k
121M 496k
121M 493k
120M 493k
-net/total-
recv send
120M 497k
120M 492k
54M 67M
399k 121M
393k 120M
400k 121M
397k 121M
394k 121M
398k 121M
396k 120M
378k 114M
387k 118M
180k 55M
52B 154B
52B 154B
(略)