[Eth-trunk] Example for Configuring Link Aggregation in Manual Load Balancing Mo

m7g
m7g  Diamond  (1)
7 years 10 months ago  View: 7568  Reply: 5
1F



SwitchA and SwitchB connect to devices in VLAN 10 and VLAN 20 through Ethernet links, and heavy traffic is transmitted between SwitchA and SwitchB.

SwitchA and SwitchB can provide higher link bandwidth to implement inter-VLAN communication. Reliability of data transmission needs to be ensured.



Configuration Roadmap

The configuration roadmap is as follows:

  1. Create an Eth-Trunk and add member interfaces to the Eth-Trunk to increase link bandwidth.

    NOTE:
    An interface is added to VLAN1 by default. To avoid broadcast strom, shut down the interface or remove the interface from VLAN1 before adding it to an Eth-Trunk interface.
  2. Create VLANs and add interfaces to the VLANs.

  3. Set the load balancing mode to ensure that traffic is load balanced between member interfaces of the Eth-Trunk.



Procedure

1.  Create an Eth-Trunk on SwitchA and add member interfaces to the Eth-Trunk. The configuration of SwitchB is similar to the configuration of SwitchA, and the configuration details are not mentioned here.

2.  <HUAWEI> system-view

3.  [HUAWEI] sysname SwitchA

4.  [SwitchA] interface Eth-Trunk1

5.  [SwitchA-Eth-Trunk1] trunkport gigabitethernet 0/0/1 to 0/0/3

[SwitchA-Eth-Trunk1] quit

6.  Create VLANs and add interfaces to the VLANs. The configuration of SwitchB is similar to the configuration of SwitchA, and the configuration details are not mentioned here.

# Create VLAN 10 and VLAN 20, and add interfaces to VLAN 10 and VLAN 20.

[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

# Configure Eth-Trunk 1 to allow packets from VLAN 10 and VLAN 20 to pass through.

[SwitchA] interface Eth-Trunk1

[SwitchA-Eth-Trunk1] port link-type trunk

[SwitchA-Eth-Trunk1] port trunk allow-pass vlan 10 20

7.  Set the load balancing mode of Eth-Trunk 1. The configuration of SwitchB is similar to the configuration of SwitchA, and the configuration details are not mentioned here.

8.  [SwitchA-Eth-Trunk1] load-balance src-dst-mac

9.  [SwitchA-Eth-Trunk1] quit

10.Verify the configuration.

Run the display eth-trunk 1 command in any view to check whether the Eth-Trunk is created and whether member interfaces are added.

[SwitchA] display eth-trunk 1

Eth-Trunk1s state information is:

WorkingMode: NORMAL          Hash arithmetic: According to SA-XOR-DA            

Least Active-linknumber: 1     Max Bandwidth-affected-linknumber: 8

Operate status: up             Number Of Up Port In Trunk: 3

--------------------------------------------------------------------------------

PortName                           Status       Weight

GigabitEthernet0/0/1               Up           1

GigabitEthernet0/0/2               Up           1

GigabitEthernet0/0/3               Up           1

The preceding command output shows that Eth-Trunk 1 has three member interfaces: GigabitEthernet0/0/1, GigabitEthernet0/0/2, and GigabitEthernet0/0/3. The member interfaces are both in Up state.



m7g
m7g  Diamond 
7 years 10 months ago
2F

LACP Mode



STEPS:

1.  Create Eth-Trunk 1 on SwitchA and configure Eth-Trunk 1 to work in LACP mode. The configuration of SwitchB is similar to the configuration of SwitchA, and the configuration details are not mentioned here.

2.  <HUAWEI> system-view

3.  [HUAWEI] sysname SwitchA

4.  [SwitchA] interface eth-trunk 1

5.  [SwitchA-Eth-Trunk1] mode lacp

[SwitchA-Eth-Trunk1] quit

6.  Add member interfaces to Eth-Trunk 1 on SwitchA. The configuration of SwitchB is similar to the configuration of SwitchA, and the configuration details are not mentioned here.

7.  [SwitchA] interface gigabitethernet 0/0/1

8.  [SwitchA-GigabitEthernet0/0/1] eth-trunk 1

9.  [SwitchA-GigabitEthernet0/0/1] quit

10. [SwitchA] interface gigabitethernet 0/0/2

11. [SwitchA-GigabitEthernet0/0/2] eth-trunk 1

12. [SwitchA-GigabitEthernet0/0/2] quit

13. [SwitchA] interface gigabitethernet 0/0/3

14. [SwitchA-GigabitEthernet0/0/3] eth-trunk 1

15. [SwitchA-GigabitEthernet0/0/3] quit

16. Set the system priority on SwitchA to 100 so that SwitchA becomes the Actor.

17. [SwitchA] lacp priority 100

18. On SwitchA, set the upper threshold for the number of active interfaces to 2.

19. [SwitchA] interface eth-trunk 1

20. [SwitchA-Eth-Trunk1] max active-linknumber 2

[SwitchA-Eth-Trunk1] quit

21. Set the priority of the interface and determine active links on SwitchA.

22. [SwitchA] interface gigabitethernet 0/0/1

23. [SwitchA-GigabitEthernet0/0/1] lacp priority 100

24. [SwitchA-GigabitEthernet0/0/1] quit

25. [SwitchA] interface gigabitethernet 0/0/2

26. [SwitchA-GigabitEthernet0/0/2] lacp priority 100

27. [SwitchA-GigabitEthernet0/0/2] quit

28. Verify the configuration.

# Check information about the Eth-Trunk of the Switchs and check whether negotiation is successful on the link.

[SwitchA] display eth-trunk 1

Eth-Trunk1s state information is:

Local:                                                                          

LAG ID: 1                       WorkingMode: LACP                            

Preempt Delay: Disabled         Hash arithmetic: According to SIP-XOR-DIP      

System Priority: 100            System ID: 00e0-fca8-0417

Least Active-linknumber: 1      Max Active-linknumber: 2                       

Operate status: up              Number Of Up Port In Trunk: 2

--------------------------------------------------------------------------------

ActorPortName                    Status     PortType PortPri   PortNo PortKey   PortState  Weight

GigabitEthernet0/0/1             Selected  1GE       100      6145    2865      11111100     1

GigabitEthernet0/0/2             Selected  1GE       100      6146    2865      11111100     1

GigabitEthernet0/0/3             Unselect  1GE       32768    6147    2865      11100000     1

 

Partner:

------------------------------------------------------------------------------

ActorPortName                     SysPri    SystemID    PortPri PortNo PortKey   PortState

GigabitEthernet0/0/1              32768  00e0-fca6-7f85  32768     6145   2609      11111100

GigabitEthernet0/0/2              32768  00e0-fca6-7f85  32768     6146   2609      11111100

GigabitEthernet0/0/3              32768  00e0-fca6-7f85  32768     6147   2609      11110000

[SwitchB] display eth-trunk 1

Eth-Trunk1s state information is:

Local:

LAG ID: 1                      WorkingMode: LACP

Preempt Delay: Disabled        Hash arithmetic: According to SIP-XOR-DIP

System Priority: 32768         System ID: 00e0-fca6-7f85

Least Active-linknumber: 1     Max Active-linknumber: 8

Operate status: up             Number Of Up Port In Trunk: 2

------------------------------------------------------------------------------

ActorPortName                   Status     PortType    PortPri   PortNo  PortKey   PortState  Weight

GigabitEthernet0/0/1            Selected   1GE         32768     6145    2609      11111100     1

GigabitEthernet0/0/2            Selected   1GE         32768     6146    2609      11111100     1

GigabitEthernet0/0/3            Unselect   1GE         32768     6147    2609      11100000     1

 

Partner:

------------------------------------------------------------------------------

ActorPortName                     SysPri    SystemID     PortPri  PortNo  PortKey   PortState

GigabitEthernet0/0/1              100    00e0-fca8-0417  100      6145     2865      11111100

GigabitEthernet0/0/2              100    00e0-fca8-0417  100      6146     2865      11111100

GigabitEthernet0/0/3              100    00e0-fca8-0417  32768    6147     2865      11110000

The preceding information shows that the system priority of SwitchA is 100, which is higher than the system priority of SwitchB. Member interfaces GigabitEthernet0/0/1 andGigabitEthernet0/0/2 become the active interfaces and are in Selected state. Interface GigabitEthernet0/0/3 is in Unselect state. Two links are active and working in load balancing mode, and one link is the backup links.

Felipe
Felipe  Platinum 
7 years 10 months ago
3F
Thanks for your sharing! Very interesting
m7g
m7g  Diamond 
7 years 10 months ago
4F
I will continue to post interesting material. Thank you for your positive feedback.
m7g
m7g  Diamond 
7 years 10 months ago
5F

Q: Does the Switch Eth-Trunk Port Support the Enhanced Load Balancing Mode?

A: In the enhanced mode, the load balancing can be implemented based on the packet type.

    In V100R006 and earlier versions, the swithces do not support this configuration. In V200R100, only the S5300HI supports this configuration. In V200R200 and later versions, the S5300HI and S5310EI support this configuration. The key configuration commands are as follows:
1. Run the load-balance-profile profile-name command to create the enhanced load balancing template and go to the template view. The load balancing mode can be configured for L2 packets, IPV4 packets, IPV6 packets, or MPLS packets.
2. Go to the Eth-Trunk port view, and run load-balance enhanced profile profile-name to use the enhanced load balancing mode for the Eth-Trunk.

user_2837311
user_2837311  Diamond 
3 years 9 months ago
6F
useful document, thanks