链路聚合配置
一、配置基本模式的链路聚合示例
操作步骤:
在SwitchA创建Eth-Trunk接口并加入成员接口。SwitchB配置与SwitchA类似,不再赘述。
-
<HUAWEI> system-view
-
[HUAWEI] sysname SwitchA
-
[SwitchA] interface eth-trunk 1
-
[SwitchA-Eth-Trunk1] trunkport gigabitethernet 0/0/1 to 0/0/3
-
[SwitchA-Eth-Trunk1] quit
创建VLAN并将接口加入VLAN。SwitchB配置与SwitchA类似,不再赘述。
-
<HUAWEI> system-view
-
[HUAWEI] sysname SwitchB
-
[SwitchB] interface eth-trunk 1
-
[SwitchB-Eth-Trunk1] trunkport gigabitethernet 0/0/1 to 0/0/3
-
[SwitchB-Eth-Trunk1] quit
# 创建VLAN10和VLAN20并分别加入接口。
-
[SwitchA] vlan batch 10 20
-
[SwitchA] interface gigabitethernet 0/0/4
-
[SwitchA-GigabitEthernet0/0/4] port link-type trunk
-
[SwitchA-GigabitEthernet0/0/4] port trunk allow-pass vlan 10
-
[SwitchA-GigabitEthernet0/0/4] quit
-
[SwitchA] interface gigabitethernet 0/0/5
-
[SwitchA-GigabitEthernet0/0/5] port link-type trunk
-
[SwitchA-GigabitEthernet0/0/5] port trunk allow-pass vlan 20
-
[SwitchA-GigabitEthernet0/0/5] quit
# 配置Eth-Trunk1接口允许VLAN10和VLAN20通过。
-
[SwitchA] interface eth-trunk 1
-
[SwitchA-Eth-Trunk1] port link-type trunk
-
[SwitchA-Eth-Trunk1] port trunk allow-pass vlan 10 20
配置Eth-Trunk1的负载均衡分担方式。SwitchB配置与SwitchA类似,不再赘述。
-
[SwitchA-Eth-Trunk1] load-balance src-dst-mac
-
[SwitchA-Eth-Trunk1] quit
仅供参考