
當我嘗試iperf
在本地伺服器上運行時,它會報告合理的值
iperf -c 127.0.0.1 -p 631
------------------------------------------------------------
Client connecting to 127.0.0.1, TCP port 631
TCP window size: 2.50 MByte (default)
------------------------------------------------------------
[ 3] local 127.0.0.1 port 42824 connected with 127.0.0.1 port 631
[ ID] Interval Transfer Bandwidth
[ 3] 0.0-10.0 sec 2.40 MBytes 2.01 Mbits/sec
但是當我連接到任何遠端伺服器時,它會報告非常大的值
iperf -c www.google.com -p 80
------------------------------------------------------------
Client connecting to www.google.com, TCP port 80
TCP window size: 85.0 KByte (default)
------------------------------------------------------------
[ 3] local x.x.x.x port 45329 connected with 110.164.12.55 port 80
[ ID] Interval Transfer Bandwidth
[ 3] 0.0-10.0 sec 0.00 � ��s 14746527068517650432 Bytes/sec
看起來像是某種溢出!我使用 USB EVDO 數據機的 PPP 連接來連接到 Internet,我的iperf
版本是iperf version 2.0.5 (08 Jul 2010) pthreads
.
為什麼會發生這種情況?
答案1
iperf 要求您在兩端都具有存取權限。一端運作iperf -s
又稱為伺服器模式,另一端iperf -c IP
又稱為客戶端,應使用位址 IP 連接到伺服器。您不能只是將客戶端指向隨機打開的連接埠並期望它能夠工作。它需要另一端的 iperf 伺服器。