Configure link aggregation on Huawei switches (link aggregation in manual mode and aggregation in lacp mode)

Configure Link Aggregation on Huawei Switches

Link aggregation (Eth-Trunk) is to bundle multiple physical interfaces into one logical interface to achieve the purpose of increasing link bandwidth, improving reliability, and providing load sharing.

There are two modes of link aggregation: manual load sharing mode (default mode, default load balancing mode src-dst-ip), LACP mode (recommended).

1. In manual mode, the establishment of Eth-Trunk and the addition of member interfaces are manually configured without the participation of LACP. In manual mode, all active links participate in data forwarding and share traffic evenly. If an active link fails, the link aggregation group will automatically share the traffic evenly among the remaining active links.

When a larger link bandwidth needs to be provided between two directly connected devices, but one or both ends of the device do not support the LACP protocol, you can configure link aggregation in manual mode.
insert image description here

SW1

[SW1]interface Eth-Trunk 1
[SW1-Eth-Trunk1]mode manual load-balance //Select manual load balancing, the default is manual mode, you can not configure it

[SW1-Eth-Trunk1]load-balance ? //Check the configurable mode, the default is src-dst-ip,
dst-ip According to destination IP hash arithmetic
dst-mac According to destination MAC hash arithmetic
src-dst- ip According to source/destination IP hash arithmetic //default configuration
src-dst-mac According to source/destination MAC hash arithmetic
src-ip According to source IP hash arithmetic
src-mac According to source MAC hash arithmetic

[SW1-Eth-Trunk1]load-balance src-dst-ip //use src-dst-ip here

[SW1-Eth-Trunk1]trunkport GigabitEthernet 0/0/1 to 0/0/2 //Add GE0/0/1 to GE0/0/2

Configure Eth-Trunk 1 as trunk mode, and allow vlan 10 and 20
[SW1]interface Eth-Trunk 1
[SW1-Eth-Trunk1]port link-type trunk
[SW1-Eth-Trunk1]port trunk allow-pass vlan 10 20

SW2
[SW2]interface Eth-Trunk 1
[SW2-Eth-Trunk1]mode manual load-balance

[SW2-Eth-Trunk1]load-balance src-dst-ip

[SW2-Eth-Trunk1]trunkport GigabitEthernet 0/0/1 to 0/0/2

Configure Eth-Trunk 1 as a trunk and allow vlan10 and 20
[SW2]interface Eth-Trunk 1
[SW2-Eth-Trunk1]port link-type trunk
[SW2-Eth-Trunk1]port trunk allow-pass vlan 10 20

Use the command display eth-trunk 1 to view
insert image description here

**===============================================================**

2. LACP mode
When a large link bandwidth needs to be provided between two directly connected devices and both devices support the LACP protocol, it is recommended to use LACP mode.
LACP mode can not only achieve the purpose of increasing bandwidth, improving reliability, and load sharing, but also can improve the fault tolerance of Eth-Trunk and provide backup functions.
In LACP mode, some links are active links, and all active links participate in data forwarding. If an active link fails, the link aggregation group automatically selects one of the inactive links as the active link to participate in data forwarding.

As shown in the figure below, GE0/0/1, GE0/0/2, and GE0/0/3 of SW1 and SW2 are added to the link aggregation, and GE0/0/3 is used as the backup link.
insert image description here
configuration process

SW1

[SW1]interface Eth-Trunk 2 //Create eth-trunk 2 aggregation port
[SW1-Eth-Trunk2]mode lacp-static //Configure mode is lacp static mode
[SW1-Eth-Trunk2]trunkport GigabitEthernet 0/0/1 to 0/0/3 //Add GE0/0/1 to GE0/0/3 to the aggregation group

Configure the system priority on SW1 to be 100 to make it the LACP active end
[SW1]lacp priority 100

Configure the upper threshold of the active interface on SW1 to be 2
[SW1]interface Eth-Trunk 2
[SW1-Eth-Trunk2]max active-linknumber 2

Enter the physical interface in SW1 to configure the interface priority and determine the active link. Only GE1 and GE2 ports are configured here, and the default value of GE3 port is 32768.
[SW1]interface GigabitEthernet 0/0/1
[SW1-GigabitEthernet0/0/1]lacp priority 100
[SW1]interface GigabitEthernet 0/0/2
[SW1-GigabitEthernet0/0/2]lacp priority 100

Configure the Eth-Trunk2 interface as a trunk, and allow VLAN10 and VLAN20 to pass through (the vlan configuration process is omitted)
[SW1]interface Eth-Trunk 2
[SW1-Eth-Trunk2]port link-type trunk
[SW1-Eth-Trunk2]port trunk allow -pass vlan 10 20


SW2

[SW2]interface Eth-Trunk 2
[SW2-Eth-Trunk2]mode lacp-static //The configuration mode is lacp static mode

Add GE0/0/1, GE0/0/2, and GE0/0/3 to the aggregation port respectively (another method used here, not in batches)

[SW2]interface GigabitEthernet 0/0/1
[SW2-GigabitEthernet0/0/1]eth-trunk 2

[SW2]interface GigabitEthernet 0/0/2
[SW2-GigabitEthernet0/0/2]eth-trunk 2

[SW2]interface GigabitEthernet 0/0/3
[SW2-GigabitEthernet0/0/3]eth-trunk 2

Keep the default priority on SW2, and configure the upper threshold of the active interface on SW2 to be 2
[SW2]interface Eth-Trunk 2
[SW2-Eth-Trunk2]max active-linknumber 2

Configure the Eth-Trunk2 interface as a trunk, and allow VLAN10 and VLAN20 to pass through (the vlan configuration process is omitted)
[SW2]interface Eth-Trunk 2
[SW2-Eth-Trunk2]port link-type trunk
[SW2-Eth-Trunk2]port trunk allow -pass vlan 10 20

Use the command display eth-trunk 2 to view the interface status on SW1 and SW2 respectively.
View on SW1insert image description here

SW2insert image description here


Shutdown GE0/0/1 port of SW1,
[SW1]interface GigabitEthernet 0/0/1
[SW1-GigabitEthernet0/0/1]shutdown

Check the aggregation port again, GE0/0/3 has been switched to the selected state.
insert image description here

3. Mode
1 is commonly used by switches and other devices for link aggregation. When interconnecting with servers,
the link aggregation modes of servers and access devices must match. When the server selects the static link aggregation mode, the corresponding access device should select the manual mode; when the server selects the IEEE 802.3ad dynamic link aggregation mode, the corresponding access device should select the LACP mode.
2. When interconnecting with stacking devices,
the switch and the stacking system are interconnected through link aggregation, and at the same time enable the local priority forwarding function of Eth-Trunk interface traffic, which can reduce the bandwidth bearing pressure between stacking devices while ensuring reliable transmission of data traffic , improving the traffic forwarding efficiency.

Guess you like

Origin blog.csdn.net/qq_33292195/article/details/121923939