![下载速度慢 WAN -> pfSense -> PC](https://linux22.com/image/1629816/%E4%B8%8B%E8%BD%BD%E9%80%9F%E5%BA%A6%E6%85%A2%20WAN%20-%3E%20pfSense%20-%3E%20PC.png)
我在我的家庭网络中观察到了奇怪的现象。虽然 LAN 中的所有组件之间都实现了全千兆速度,路由器和 NAS 之间的 WAN 也实现了全速,但 PC 从 WAN 下载时只能达到大约 400 MBit。所有测量都是使用 iperf3 进行的,并且在路由器上禁用了 QoS/Traffic-Shaping。谁能解释一下?
MODEM (WAN)
|
ROUTER
| 192.168.1.*
NAS---SWITCH---PC
LAN: Gigabit
WAN: 500 down, 50 up
NAS: Synology 218j
PC: [email protected], Realtek PCIe GbE Family Controller, Windows 10
ROUTER: Celeron j1900@2Ghz, pfSense 2.4.5_1, Intel NIC (igb)
iperf3 (-P 10)
NAS (client) <-> PC (server)
download: 941 MBit (-R)
upload: 942 MBit
NAS (client) <-> ROUTER (server)
download: 931 MBit (-R)
upload: 945 MBit
PC (client) <-> NAS (server)
download: 941 MBit (-R)
upload: 941 MBit
PC (client) <-> ROUTER (server)
download: 937 MBit (-R)
upload: 935 MBit
ROUTER (client) <-> NAS (server)
download: 944 MBit (-R)
upload: 930 MBit
ROUTER (client) <-> PC (server)
download: 936 MBit (-R)
upload: 933 MBit
ROUTER (client) <-> WAN (server)
download: 536 MBit (-R)
upload: 50 MBit
NAS (client) <-> WAN (server)
download: 537 MBit (-R)
upload: 48 MBit
PC (client) <-> WAN (server)
download: 400 MBit (-R)
upload: 49 MBit
更新:我通过在 iperf3 命令中添加“-w 300000”,成功地将从 WAN 到 PC 的下载速度提升到预期的 ~530 MBit:
-w, --window #[KMG] set window size / socket buffer size
剩下的问题是:为什么我只需要在 Windows 系统上进行此设置(NAS 运行 Linux 3.10,路由器运行一些 FreeBSD),为什么它只影响从 WAN 下载而不影响从 LAN 下载(也许是延迟?WAN-iperf-server ~25ms)。
解决方案:我在这里下载了当前的 iperf3 版本 (3.8.1):
https://www.neowin.net/forum/topic/1234695-iperf-381-windows-build/page/3/
iperf3 官方网站仅提供 Windows 版本至 3.1.3。使用新版本,Windows PC 上的 iperf 下载速度与 Linux 和 FreeBSD 系统的速度相同。