华为交换机如何做端口聚合
发布网友
发布时间:2022-04-20 00:59
我来回答
共1个回答
热心网友
时间:2022-05-23 16:52
静态方式:
[sw1]interface eth-trunk 1
[sw1-Eth-Trunk1]port link-type trunk
[sw1-Eth-Trunk1]port trunk allow-pass vlan all
[sw1-Eth-Trunk1]load-balance src-dst-ip
[sw1-Eth-Trunk1]q
[sw1]int e0/0/1
[sw1-Ethernet0/0/1]eth-trunk 1
[sw1-Ethernet0/0/1]q
[sw1]int e0/0/2
[sw1-Ethernet0/0/2]eth-trunk 1
[sw1-Ethernet0/0/2]q
sw2配置:
[sw2]
[sw2]interface eth-trunk 1
[sw2-Eth-Trunk1]port link-type trunk
[sw2-Eth-Trunk1]port trunk allow-pass vlan all
[sw2-Eth-Trunk1]load-balance src-dst-ip
[sw2-Eth-Trunk1]q
[sw2]int e0/0/1
[sw2-Ethernet0/0/1]eth-trunk 1
[sw2-Ethernet0/0/1]int e0/0/2
[sw2-Ethernet0/0/2]eth-trunk 1
[sw2-Ethernet0/0/2]q
LACP静态聚合:
[Huawei]sysname sw1
[sw1]interface eth-trunk 1
[sw1-Eth-Trunk1]mode lacp-static
[sw1-Eth-Trunk1]load-balance src-dst-ip //根据源目的ip逐流负载分担
[sw1-Eth-Trunk1]max active-linknumber 2 //最大激活2条链路
[sw1-Eth-Trunk1]lacp preempt enable //开启抢占模式,故障恢复后优先的链路才可恢复通信
[sw1-Eth-Trunk1]bp enable
[sw1-Eth-Trunk1]port link-type trunk
[sw1-Eth-Trunk1]port trunk allow-pass vlan all
[sw1-Eth-Trunk1]q
[sw1]lacp priority 100 //系统优先级默认32768,越小越优先,据此确定主动端
[sw1]int e0/0/1
[sw1-Ethernet0/0/1]eth-trunk 1
Info: This operation may take a few seconds. Please wait for a moment...done.
[sw1-Ethernet0/0/1]lacp priority 100 //端口优先级默认32768,小好,据此确定哪个端口链路处于selected
[sw1-Ethernet0/0/1]q
[sw1]int e0/0/2
[sw1-Ethernet0/0/2]eth-trunk 1
[sw1-Ethernet0/0/2]lacp priority 100
[sw1-Ethernet0/0/2]q
[sw1]
[sw1]int e0/0/3
[sw1-Ethernet0/0/3]eth-trunk 1
[sw1-Ethernet0/0/3]lacp priority 300
[sw1-Ethernet0/0/3]q
sw2配置:
[sw2]interface eth-trunk 1
[sw2-Eth-Trunk1]mode lacp-static
[sw2-Eth-Trunk1]bp enable
[sw2-Eth-Trunk1]port link-type trunk
[sw2-Eth-Trunk1]port trunk allow-pass vlan all
[sw2-Eth-Trunk1]q
[sw2]lacp priority 300
[sw2]int e0/0/1
[sw2-Ethernet0/0/1]eth-trunk 1
[sw2-Ethernet0/0/1]q
[sw2]int e0/0/2
[sw2-Ethernet0/0/2]eth-trunk 1
[sw2-Ethernet0/0/2]q
[sw2]int e0/0/3
[sw2-Ethernet0/0/3]eth-trunk 1
[sw2-Ethernet0/0/3]q