Skip to main content

Two 25 GbE Links, One Slow Backup

Updated 3 min readMarkdown

A server gets a second 25 GbE uplink. Both ports join the LACP bundle, but the overnight backup takes just as long. Before changing the switch, check whether the backup uses one TCP connection and which physical port carried its bytes. That tells you whether the second link even had a chance to help.

See which port the sender chose

On a bundle that uses per-flow hashing, the sender picks an outgoing member using fields such as MAC addresses, IP addresses, or TCP and UDP ports. A steady TCP flow with the same hash inputs stays on one member while the bundle is stable. Two 25 GbE members can carry up to 50 Gb/s of aggregate line rate in one direction when traffic is spread across both. One flow assigned to a single member has that member's 25 Gb/s line rate as its ceiling, with less available for TCP payload. Cisco Nexus 9000 port-channel guide

Check the direction that carries the backup data. For a Linux host sending on an 802.3ad bond, the host's xmit_hash_policy selects the outgoing member. On the way back, the switch applies its own transmit policy to traffic it sends toward the host. If that policy sees only the same pair of IP addresses, adding TCP connections between those addresses gives it no new input to hash. Even when the policy includes TCP ports, different connections can still land on the same member. Linux bonding driver HOWTO

Put the member counters next to the test

First verify that both ports are in the same active aggregate and are forwarding. A port can have physical link without carrying traffic for the bundle. On Linux, cat /proc/net/bonding/bond0 shows bond and member status. Take a before-and-after snapshot of RX and TX bytes on each physical interface with ip -s link show dev INTERFACE, replacing INTERFACE with its actual name. The total on bond0 cannot tell you which cable carried the test. Linux bonding status · Linux interface statistics

Use a test path with enough capacity beyond the bundle, and run the test in a lab or maintenance window. Start iperf3 -s on the test peer. On the bonded host, replace SERVER_IP with the peer's address and run these separately.

iperf3 -c SERVER_IP -P 1
iperf3 -c SERVER_IP -P 4

Compare the TX byte increases on both members for each run. To test the opposite direction, repeat the commands with -R and compare RX byte increases on the bonded host. Keep background traffic low enough to distinguish it from the test. A higher result with four streams is only part of the evidence. Since version 3.16, iperf3 uses a thread per test stream, so extra CPU capacity can also raise throughput. The member counters tell you whether traffic actually spread across both ports. ESnet iperf3 manual

If four streams move more bytes across both members but the backup still uses one connection, check whether the backup software can open parallel connections. If a single stream falls well short of one member's capacity, check the test hosts and the rest of the path before attributing the shortfall to the bundle. An unchanged backup window can still have a storage bottleneck, even after a network-only test shows both links working.

OpenAI Codex assisted with drafting this article. The technical references are linked alongside the relevant guidance.

“bond0 的总数看不出是哪根线在干活”这句太关键了,我以前也在这上面栽过:加了第二条链路,以为备份窗口能减半,结果时间纹丝不动,当时只盯着总带宽看,怎么都想不通。想问一句:你们那个备份任务本身是单流还是多流?如果备份软件只开一条 TCP 连接,就算 iperf3 -P 4 能跑满两条线,备份还是卡在一条 25G 上吧。

More from this blog