Linux 下 lacp bond 模式的疑问
- 0次
- 1975-02-25 05:25:00
- idczone
Transmit Hash Policy 无论是 layer2 layer2+3 layer3+4 流量只走端口 1 ,如果有另一台设备连接才会走端口 2
我想问一下是哪里配置错了吗?
Ethernet Channel Bonding Driver: v3.7.1 (April 27, 2011)
Bonding Mode: IEEE 802.3ad Dynamic link aggregation
Transmit Hash Policy: layer2+3 (2)
MII Status: up
MII Polling Interval (ms): 100
Up Delay (ms): 0
Down Delay (ms): 0
802.3ad info
LACP rate: fast
Min links: 0
Aggregator selection policy (ad_select): stable
System priority: 65535
System MAC address: 1c:98:ec:0e:11:08
Active Aggregator Info:
Aggregator ID: 1
Number of ports: 2
Actor Key: 9
Partner Key: 77
Partner Mac Address: 80:c1:6e:d0:b4:f0
Slave Interface: eno1
MII Status: up
Speed: 1000 Mbps
Duplex: full
Link Failure Count: 1
Permanent HW addr: 1c:98:ec:0e:11:08
Slave queue ID: 0
Aggregator ID: 1
Actor Churn State: none
Partner Churn State: none
Actor Churned Count: 0
Partner Churned Count: 0
details actor lacp pdu:
system priority: 65535
system mac address: 1c:98:ec:0e:11:08
port key: 9
port priority: 255
port number: 1
port state: 63
details partner lacp pdu:
system priority: 46320
system mac address: 80:c1:6e:d0:b4:f0
oper key: 77
port priority: 0
port number: 1
port state: 61
Slave Interface: eno2
MII Status: up
Speed: 1000 Mbps
Duplex: full
Link Failure Count: 1
Permanent HW addr: 1c:98:ec:0e:11:09
Slave queue ID: 0
Aggregator ID: 1
Actor Churn State: none
Partner Churn State: none
Actor Churned Count: 0
Partner Churned Count: 0
details actor lacp pdu:
system priority: 65535
system mac address: 1c:98:ec:0e:11:08
port key: 9
port priority: 255
port number: 2
port state: 63
details partner lacp pdu:
system priority: 46320
system mac address: 80:c1:6e:d0:b4:f0
oper key: 77
port priority: 0
port number: 2
port state: 61
是怎么“确认”流量只走端口 1 的呢?
记得一个 TCP stream 是不会被分发到多个 NIC 上的,始终走同一个 NIC (我认为不然的话开销太大,得不偿失)。
你试试多个 TCP stream ,多个不同的目标地址。
Ref:
- https://serverfault.com/questions/569721/can-bonding-2-interfaces-double-the-speed
- https://serverfault.com/questions/569060/link-aggregation-lacp-802-3ad-max-throughput/569125#569125
HP 的交换机 web 界面可以看每个端口的流量,用 iperf 测试的;同样的物理连接 Linux 下配置 mode=0(balance-rr)是可以正常负载均衡的
看来是我对 LACP 的理解有点问题(捂脸中)