01-03 Link Aggregation Configuration
01-03 Link Aggregation Configuration
Switches
Configuration Guide - Ethernet Switching 3 Link Aggregation Configuration
Link aggregation is a technology that bundles multiple Ethernet links into a logical
link to increase bandwidth, improve reliability, and load balance traffic.
Purpose
As networks grow in scale, users require Ethernet backbone networks to provide
higher bandwidth and reliability. In the past, to increase the bandwidth, users had
to replace legacy devices with high-speed devices. This solution, however, is costly
and inflexible.
● Increased bandwidth
The bandwidth of the link aggregation interface is the sum of the bandwidth
of member interfaces.
● Higher reliability
When an active link fails, traffic on this active link moves to another active
link, improving reliability of the link aggregation interface.
● Load balancing
In a link aggregation group (LAG), traffic is load balanced among active link
members.
3.2.1 Concepts
In Figure 3-1, DeviceA and DeviceB are connected through three Ethernet physical
links. These links bundle into a logical link, and their bandwidths are combined to
form the total bandwidth of the logical link. The three physical Ethernet links
provide backup for each other, improving reliability.
NOTE
Both devices connected by the Eth-Trunk must use the same number of physical interfaces,
interface rate, jumbo, and flow control mode.
The upper threshold for the number of active interfaces is inapplicable to the manual
load balancing mode. For details about the manual load balancing mode, see 3.2.3
Link Aggregation in Manual Load Balancing Mode.
● Lower threshold for the number of active interfaces
When the number of active interfaces falls below the lower threshold, the
Eth-Trunk goes Down. This guarantees the minimum available bandwidth for
the Eth-Trunk.
For example, if the Eth-Trunk is required to provide a minimum bandwidth of
2 Gbit/s and each member link's bandwidth is 1 Gbit/s, the lower threshold
must be set to 2 or larger.
traffic evenly. The manual load balancing mode is suitable in scenarios where the
link between two directly connected devices requires a high bandwidth but the
devices do not support the LACP protocol.
Concepts
● LACP system priority
LACP system priorities determine the sequence in which devices at two ends
of an Eth-Trunk select active interfaces to join a LAG. In order for a LAG to be
established, both devices must select the same interfaces as active interfaces.
To achieve this, one device (with a higher priority) is responsible for selecting
the active interfaces. The other device (with a lower priority) then selects the
same interfaces as active interfaces. In priority comparisons, numerically
lower values have higher priority.
Figure 3-6 Selecting the Actor and active links in LACP mode
● LACP preemption
When LACP preemption is enabled, interfaces with higher priorities in a LAG
always function as active interfaces.
As shown in Figure 3-7, Port 1, Port 2, and Port 3 are member interfaces of
an Eth-Trunk; DeviceA acts as the Actor; the upper threshold for the number
of active interfaces is 2; LACP priorities of Port 1, Port 2, and Port 3 are 10, 20,
and 30 respectively. When LACP negotiation is complete, Port 1 and Port 2 are
selected as active interfaces because their LACP priorities are higher, and Port
3 is used as the backup interface.
On the network shown in Figure 3-8, DeviceA and DeviceB are directly
connected and both of them support LACP. The Eth-Trunk working in static
LACP mode can be configured on the two devices to implement load
balancing and link backup. The static LACP mode is mainly applied to
situations where the bandwidth of M links must be assured and a fault
tolerance mechanism is in place. If an active link fails, the system selects the
backup link with the highest priority as the active link.
NOTE
Eth-Trunk in dynamic LACP mode can be used only in a scenario where a Huawei device is
interconnected with a server. (Ports on the server must be isolated from each other. For
example, NICs on the server cannot be configured to work in bridge mode. If the ports are not
isolated, loops may occur on the network.) In other scenarios, you are advised to deploy Eth-
Trunk in static LACP mode.
When an Eth-Trunk is used to forward data frames, data frames of the same data
flow may be transmitted over different physical links. This mode ensures optimal
bandwidth utilization. However, data frames may arrive at the destination in a
different order to which they were transmitted, resulting to mis-sequencing.
Concepts
● Stack device
The stack device is a logical device formed by connecting multiple devices
through dedicated stack cables. In Figure 3-10, DeviceB and DeviceC are
connected to form a logical device.
● Inter-device Eth-Trunk
An inter-chassis Eth-Trunk contains physical interfaces of multiple devices in a
stack. When a device in the stack fails or a physical interface added to the
Eth-Trunk fails, traffic can be transmitted between devices through stack
cables. This ensures reliable transmission and implements device backup.
● Preferential forwarding of local traffic
In network b of Figure 3-10, traffic from DeviceB or DeviceC is only
forwarded through local member interfaces when the network runs properly.
In network a of Figure 3-10, traffic is forwarded across devices through stack
cables.
● This function is only valid for known unicast packets, and is invalid for unknown unicast,
broadcast, and multicast packets.
● Before configuring an Eth-Trunk to preferentially forward local traffic, ensure that
member interfaces of the local Eth-Trunk have sufficient bandwidth to forward local
traffic; otherwise, traffic may be discarded.
Stacking
Interfaces on member switches in a stack can be bundled into an Eth-Trunk.
This inter-device link aggregation mode is applied to scenarios where the stack is
connected to other devices, and protects the link between upstream and
downstream devices. The Eth-Trunk can still work even if a member switch fails or
one link of the Eth-Trunk fails, ensuring reliable transmission of data traffic. This
prevents single-point failures of a member device in a stack and greatly improves
the network-wide reliability.
For details, see Stack Configuration in the CloudEngine 9800, 8800, 6800, 5800
Series Switches Configuration Guide - Virtualization Configuration Guide.
M-LAG
M-LAG allows two access switches in the same state to perform link aggregation
negotiation with the access device. In Figure 3-12, the access device
communicates with the M-LAG through link aggregation, achieving device-level
reliability instead of only card-level reliability. The M-LAG is a dual-active system
that is composed of two access switches.
M-LAG is a horizontal virtualization technology that virtualizes two M-LAG devices
into one logical device, that is, a unified Layer 2 logical node. In practice, M-LAG
provides loop-free networking between aggregation and access layers and
replaces STP. Compared with STP, M-LAG provides clear logical topology and
better link use efficiency.
M-LAG master and backup devices forward data simultaneously and their
forwarding behaviors are the same. The forwarding behaviors of M-LAG master
and backup device roles are different only in scenarios where faults occur.
For details, see M-LAG Configuration in the CloudEngine 9800, 8800, 6800, 5800
Series Switches Configuration Guide - Ethernet Switching Configuration Guide.
M-LAG Lite
Figure 3 shows the inter-device link aggregation on the M-LAG Lite networking.
Compared with inter-device link aggregation in a stack or M-LAG system, inter-
device link aggregation in an M-LAG Lite system removes the heartbeat cable
(iStack link or peer-link) required for establishing a stack/M-LAG between devices.
Inter-device link aggregation in an M-LAG Lite system simplifies deployment,
saves costs, and ensures that services are not interrupted during the upgrade.
In Figure 3, the same Eth-Trunk ID, LACP system ID, LACP system priority, and
different numbers of Eth-Trunk member interfaces are configured on DeviceB and
DeviceC. (On one member device, the lacp port-id-extension enable command is
run in views of all the member interfaces to increase the number of each member
interface by 32768.) In this way, the inter-device Eth-Trunk interface negotiation
can be successful. The two devices evenly load balance data. When one device
fails, traffic can be forwarded through the other device, implementing device-level
reliability.
DeviceB and DeviceC must be Layer 3 gateways and cannot be Layer 2 transparent
transmission devices. If an upstream device functions as the gateway, the ARP and
ND entries of the server or switch learned by the gateway have two egresses,
causing MAC address flapping. Therefore, the devices to which the server or switch
connects in M-LAG Lite mode must be Layer 3 gateways.
For details about M-LAG Lite, see "Example for Configuring M-LAG Lite" in
Configuration Examples for Comprehensive Scenarios in the CloudEngine 9800,
8800, 6800, 5800 Series Switches Configuration Guide - Typical Configuration
Examples. For details about IPv6 M-LAG Lite, see "Example for Configuring IPv6
M-LAG Lite" in Configuration Examples for Comprehensive Scenarios in the
CloudEngine 9800, 8800, 6800, 5800 Series Switches Configuration Guide - Typical
Configuration Examples.
You can determine the working mode for the Eth-Trunk according to the following
situations:
● If devices at both ends of the Eth-Trunk support LACP, the LACP mode is
recommended.
● If the device at either end of the Eth-Trunk does not support LACP, you must
use the manual load balancing mode.
Licensing Requirements
Ethernet link aggregation is a basic function of the switch, and as such is
controlled by the license for basic software functions. The license for basic
software functions has been loaded and activated before delivery. You do not need
to manually activate it.
Version Requirements
Table 3-2 Products and minimum version supporting Ethernet link aggregation
CE9860EI V200R020C00
CE8861EI/CE8868EI V200R005C10
CE8850-32CQ-EI V200R002C50
CE8850-64CQ-EI V200R005C00
CE6856HI V200R002C50
CE6857EI V200R005C10
CE6865EI V200R005C00
CE6870-48S6CQ-EI V200R001C00
CE6870-48T6CQ-EI V200R002C50
CE6881K V200R019C10
CE6881E V200R019C10
CE6863K V200R019C10
CE5881 V200R020C00
CE5855E V200R020C10
CE6857E V200R020C10
NOTE
For details about the mapping between software versions and switch models, see the
Hardware Query Tool.
Software version evolution:
● For switches excluding the CE9860EI, CE6881, CE6881E, CE6881K, CE6863, CE6863K,
CE6857E, CE6820, CE5881, and CE5855E
V100R001C00 -> V100R002C00 -> V100R003C00 -> V100R003C10 -> V100R005C00 ->
V100R005C10 -> V100R006C00 -> V200R001C00 -> V200R002C50 -> V200R003C00 ->
V200R005C00 -> V200R005C10 -> V200R019C00 -> V200R019C10 -> V200R020C10
● For the CE9860EI, CE6881, CE6881E, CE6881K, CE6863, CE6863K, CE6857E, CE6820,
CE5881, CE5855E
V200R005C20 -> V200R019C10 -> V200R020C00 -> V200R020C10
Feature Limitations
Licensing Requirements and Limitations Before an Eth-Trunk Is Configured
● Each Eth-Trunk supports a maximum of 128 member interfaces on the
CE6881, CE5881, CE6881K, CE6820, CE6863K, CE6881E, and CE6863. Each Eth-
Trunk supports a maximum of 64 member interfaces on the CE9860EI. The
maximum number of member interfaces in each Eth-Trunk on other models is
determined by the assign forward eth-trunk mode command.
● In distributed forwarding mode, switches can be configured with less than 256
link aggregation groups.
● In versions earlier than V200R002C50, member interfaces of an Eth-Trunk
must use the same rate.
For example, GE and 10GE interfaces cannot join the same Eth-Trunk,
whereas GE electrical and optical interfaces can join the same Eth-Trunk.
In V200R002C50 and later versions, Ethernet interfaces working with different
rates can join the same Eth-Trunk.
Upper threshold for the number of 128 on the CE6881, CE5881, CE6881K,
active member links CE6820, CE6863K, CE6881E, and
CE6863, 64 on the CE9860EI. 32 on the
CE6870EI, and 16 on other models.
Context
Typically, the number of LAGs supported by a switch is fixed. However, you can
run the assign forward eth-trunk mode command to flexibly set the number of
LAGs supported by a switch, implementing flexible networking and meeting
diversified service requirements.
NOTE
The number of LAGs supported by the CE9860EI, CE6881, CE5881, CE6881K, CE6820,
CE6863, CE6863K, CE6881E is fixed. The CE6881, CE5881, CE6881K, CE6820, CE6863,
CE6863K, CE6881E do not support a variable number of LAGs.
Procedure
Step 1 Run system-view
Step 2 Run assign forward eth-trunk mode { 64 | 128 | 256 | 512 | 1024 }
For CE6870EI, the number of LAGs supported by the device can be set using the
assign forward eth-trunk mode { 256 | 512 | 1024 } command.
By default, the CE6870EI support 512 LAGs; other models support 128 LAGs.
NOTE
After the assign forward eth-trunk mode command is used to change the number of
LAGs supported by the device, restart the device to make the configuration take effect.
Configure the number of Eth-Trunk ID resources reserved for the IPv6 VXLAN
function.
NOTE
Only the CE6857EI, CE6857E, CE6865EI, CE8861EI, and CE8868EI support this command.
----End
Context
Each LAG has one logical interface, that is, an Eth-Trunk. Before configuring link
aggregation, create an Eth-Trunk.
Procedure
Step 1 Run system-view
If the specified Eth-Trunk already exists, this command directly displays the Eth-
Trunk interface view.
Advised to create Eth-Trunks in ascending order.
trunk-id defines the Eth-Trunk ID. The value ranges of different models are
different. Table 3-4 lists value ranges of different models.
CE6870EI The value range can be adjusted using the assign forward
eth-trunk mode { 256 | 512 | 1024 } command.
● When 256 is specified, the value is in the range 0 to
255. Each Eth-Trunk allows a maximum of 64 member
interfaces.
● When 512 is specified, the value is in the range 0 to
511. Each Eth-Trunk allows a maximum of 32 member
interfaces. The default value is 512.
● When 1024 is specified, the value is in the range 0 to
1023. Each Eth-Trunk allows a maximum of 16 member
interfaces.
CE6881, CE5881, The value range cannot be adjusted. The value of trunk-id
CE6881K, CE6820, is in the range 0 to 1023. Each Eth-Trunk allows a
CE6863, CE6863K, maximum of 128 member interfaces.
CE6881E
CE8850-64CQ-EI The value range can be adjusted using the assign forward
eth-trunk mode { 32 | 64 | 128 | 256 | 512 | 1024 }
command.
● When 32 is specified, the value is in the range 0 to 31.
Each Eth-Trunk allows a maximum of 64 member
interfaces.
● When 64 is specified, the value is in the range 0 to 63.
Each Eth-Trunk allows a maximum of 32 member
interfaces.
● When 128 is specified, the value is in the range 0 to
127. Each Eth-Trunk allows a maximum of 16 member
interfaces. The default value is 128.
● When 256 is specified, the value is in the range 0 to
255. Each Eth-Trunk allows a maximum of 8 member
interfaces.
● When 512 is specified, the value is in the range 0 to
511. Each Eth-Trunk allows a maximum of 4 member
interfaces.
● When 1024 is specified, the value is in the range 0 to
1023. Each Eth-Trunk allows at most 2 member
interfaces.
Other models: The value range can be adjusted using the assign forward
eth-trunk mode { 64 | 128 | 256 | 512 | 1024 } command.
● When 64 is specified, the value is in the range 0 to 63.
Each Eth-Trunk allows a maximum of 32 member
interfaces.
● When 128 is specified, the value is in the range 0 to
127. Each Eth-Trunk allows a maximum of 16 member
interfaces. The default value is 128.
● When 256 is specified, the value is in the range 0 to
255. Each Eth-Trunk allows a maximum of 8 member
interfaces.
● When 512 is specified, the value is in the range 0 to
511. Each Eth-Trunk allows a maximum of 4 member
interfaces.
● When 1024 is specified, the value is in the range 0 to
1023. Each Eth-Trunk allows at most 2 member
interfaces.
----End
Context
Link aggregation can work in manual load balancing mode and LACP mode.
In manual load balancing mode, you must manually create an Eth-Trunk and add
member interfaces to the Eth-Trunk. All active links forward data and evenly load
balance traffic. The manual load balancing mode is used when the remote device
does not support LACP.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run interface eth-trunk trunk-id
The Eth-Trunk interface view is displayed.
Step 3 Run mode manual [ load-balance ]
The Eth-Trunk is configured to work in manual load balancing mode.
By default, an Eth-Trunk works in manual load balancing mode.
Before configuring an Eth-Trunk, ensure that both devices use the same working
mode.
Step 4 Run commit
The configuration is committed.
----End
Procedure
● Add member interfaces to an Eth-Trunk in the Eth-Trunk interface view.
a. Run system-view
The system view is displayed.
b. Run interface eth-trunk trunk-id
The Eth-Trunk interface view is displayed.
c. Run trunkport interface-type { interface-number1 [ to interface-
number2 ] } &<1-n>
A member interface is added to the Eth-Trunk.
When you add member interfaces to an Eth-Trunk in a batch, if one
interface cannot be added to the Eth-Trunk, all subsequent interfaces in
the batch cannot be added to the Eth-Trunk, either.
NOTE
Follow-up Procedure
When the status of an Eth-Trunk member interface changes, the system sends
traps containing the status change information for you to confirm whether the
device encounters any fault. If you want to know the ID of the Eth-Trunk to which
the member interface belongs, run the trunk-member trap in private-mib
enable command to enable Eth-Trunk member interfaces to send traps through a
private MIB. Traps sent through a private MIB carry the number of the specific
Eth-Trunk interface.
After the trunk-member trap in private-mib enable command is run, traps are
sent through a private MIB, instead of a public MIB. In this case, you can view the
traps only by using the private MIB of Huawei.
Context
The lower threshold for the number of active interfaces affects the status and
bandwidth of an Eth-Trunk. To ensure that the Eth-Trunk functions properly and is
less affected by member link status changes, set the lower threshold for the
number of active interfaces.
When the number of active interfaces falls below the lower threshold, the Eth-
Trunk goes Down. This ensures that the Eth-Trunk has a minimum available
bandwidth.
The upper threshold for the number of active interfaces is inapplicable to the
manual load balancing mode.
Procedure
Step 1 Run system-view
The lower threshold for the number of active interfaces on the local switch can be
different from that on the remote switch.
----End
Context
On an Eth-Trunk interface, you can load balance traffic among member interfaces
according to the weights configured for the member interfaces.
The higher the weight of a member interface, the heavier the load over the
member link. Therefore, you can configure a higher weight for a member interface
so that the member link can carry a heavier load.
Procedure
Step 1 Run system-view
The load balancing weight is configured for the Eth-Trunk member interface.
----End
Context
An Eth-Trunk supports per-packet load balancing and per-flow load balancing.
● Per-packet load balancing can improve Eth-Trunk bandwidth efficiency to
ensure even load balancing among equal-cost routes, but cannot prevent
packet mis-sequencing. To ensure packet sequencing, confirm that the device
or terminal receiving traffic supports packet reassembly in case of packet mis-
sequencing. Switches support the following per-packet load balancing modes:
– Random mode: The outbound interface of packets is generated randomly
and calculated based on the time when the packets reach the Eth-Trunk.
When the IP address and MAC address of known unicast packets remain
unchanged, configure random per-packet load balancing.
IPv4 packets src-ip, dst-ip, l4- src-ip, dst-ip, l4- The load
src-port and l4- src-port, l4-dst- balancing mode
dst-port port, and is relevant to the
protocol packet type and
irrelevant to the
IPv6 packets src-ip, dst-ip, l4- src-ip, dst-ip, packet
src-port, and l4- protocol, l4-src- forwarding
dst-port port, and l4-dst- process.
port
For example,
MPLS packets Ingress/Egress/ For switches even if the
Transit: top- excluding the system provides
label and 2nd- CE6865EI, only Layer 2
label CE6857EI, forwarding for
CE6857E, IPv4 packets, the
CE8861EI, IPv4 packets are
CE8868EI: load balanced
according to the
Ingress/Egress/
load balancing
Transit: top-
mode for IPv4
label, 2nd-label,
packets. When
dst-ip, and src-ip
the system
For the cannot identify
CE6857EI, IPv4, IPv6, or
CE6857E, MPLS packets,
CE6865EI, the system load
CE8861EI, and balances packets
CE8868EI: based on src-
Ingress/Egress/ mac, dst-mac,
Transit: top- src-interface,
label, 2nd-label, and eth-type for
3rd-label, 4th- Layer 2 packets.
label, 5th-label,
dst-ip, src-ip,
and src-
interface
NOTE
Load balancing is valid only for outgoing traffic; therefore, the load balancing modes for the
interfaces at both ends of the link can be different and do not affect each other.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 (Optional) Run load-balance profile profile-name
A load balancing profile is configured and its view is displayed. profile-name
specifies the name of the load balancing profile.
By default, there is a load balancing profile named default.
Run the following commands as required. You can configure a load balancing
mode for Layer 2 packets, IPv4 packets, IPv6 packets, FCoE, and MPLS packets
respectively.
By default, the switch load balances Layer 2 packets (non-IP packets) based
on the source MAC address (src-mac) and destination MAC address (dst-
mac).
● Run ip [ src-ip | dst-ip | l4-src-port | l4-dst-port | protocol ] *
Only the CE6857EI, CE6857E, CE6865EI, CE8861EI, and CE8868EI support 3rd-label,
4th-label, 5th-label, and src-interface. If src-ip or dst-ip is configured, 4th-label or
5th-label cannot be configured.
In V200R005C10 and earlier versions, if 4th-label and 5th-label are configured for
load balancing of MPLS packets in the load balancing profile view or ECMP view, this
configuration takes effect for both Eth-Trunk and ECMP. The load balancing mode
based on src-ip and dst-ip conflicts with that based on 4th-label and 5th-label, and
the last delivered configuration takes effect. Therefore, the effective load balancing
mode is inconsistent with that in the configuration file.
● Run fcoe { dst-fcid | src-fcid } *
A load balancing mode is configured for a stack port or fabric port in the
specified load balancing profile.
By default, a stack port or fabric port load balances packets based on hash-
mode (1) and universal-id (1) in a load balancing profile.
----End
Follow-up Procedure
● Configure simulated calculation of an Eth-Trunk outbound interface.
Configure simulated calculation of an Eth-Trunk outbound interface after
specifying the 5-tuple information, source MAC address, and destination
address.
display load-balance forwarding-path unicast interface eth-trunk trunk-id src-interface interface-
type interface-number { ethtype ethtype-number | vlan vlan-id | [ [ src-ip src-ip-data | dst-ip dst-ip-
data ] * | [ src-ipv6 src-ipv6-data | dst-ipv6 dst-ipv6-data ] * ] | src-mac src-mac-data | dst-mac dst-
mac-data | protocol { protocol-number | icmp | igmp | ip | ospf | tcp [ l4-src-port src-port-data | l4-
dst-port dst-port-data ] * | udp [ l4-src-port src-port-data | l4-dst-port dst-port-data ] * } } * slot slot-
id
● Verifying the Configuration
Verify the outbound interface of packets that contain specified 5-tuple
information, source MAC address, and destination MAC address.
display port forwarding-path { src-ip src-ip-data | dst-ip dst-ip-data | src-mac src-mac-data | dst-
mac dst-mac-data | protocol { protocol-number | gre | icmp | igmp | ip | ipinip | ospf | tcp [ l4-src-
port src-port-data | l4-dst-port dst-port-data ] * | udp [ l4-src-port src-port-data | l4-dst-port dst-
port-data ] * } } *
Context
An Eth-Trunk uses flow-based load balancing. Per-flow load balancing ensures
that packets of the same data flow are forwarded on the same physical link and
those of different data flows are forwarded on different physical links.
Load balancing is valid only for outgoing traffic; therefore, interfaces at both ends
of the link can use different load balancing modes.
Table 3-6 lists load balancing modes for different types of packets.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run load-balance profile profile-name
A load balancing profile is configured and its view is displayed. profile-name
specifies the name of the load balancing profile.
By default, there is a load balancing profile named default.
Step 3 Run the following commands as required. You can configure load balancing modes
for Layer 2, IPv4, IPv6, MPLS, VPLS, TRILL, and FCoE packets, respectively.
● Run l2 [ src-mac | dst-mac | vlan | eth-type ] *
During Layer 2 forwarding, the switch load balances only IPv4, IPv6, 802.1ah, ARP, and
CFM packets based on eth-type.
During Layer 2 forwarding, an Eth-Trunk configured with Dot1q tunnel, VLAN stacking,
VLL, or VPLS cannot load balance packets based on the VLAN ID.
● Run ip [ src-ip | dst-ip | l4-src-port | l4-dst-port | protocol ] *
To load balance IPv6 packets based on the transport-layer source and destination port
numbers, run the ip [ l4-src-port | l4-dst-port ] * command.
On an IPv6 underlay network, if the IPv6 VXLAN function is enabled and the switch
functions as a transit or egress node on the MPLS network, configurations related to
the hash field in inner information in MPLS packets do not take effect in the load
balancing profile. In this scenario, the mpls inner-type { ipv4 | ipv6 | l2 | any }
command cannot be used to change the load balancing mode for MPLS packets in the
load balancing profile. Instead, you can use the source and destination IP addresses in
inner information in MPLS packets to configure a load balancing mode in the load
balancing profile.
– The mpls [ inner-ip | inner-ipv6 ] * command can be configured only when the
IPv6 VXLAN function is enabled. In addition, this command cannot be used to
configure a load balancing mode for VPLS packets. If the IPv6 VXLAN function is
disabled, the switch automatically deletes the configurations related to the mpls
[ inner-ip | inner-ipv6 ] * command.
– For the CE6870EI, if MPLS packets with four or more labels are received, Eth-Trunk
or ECMP load balancing cannot be implemented based on the inner IP header.
– For the CE6870EI, if the implicit null label is disabled and the outer label is popped
out (for example, ASBR in inter-AS VPN Option B and inter-AS VPN Option C
networking), packets may be unable to be load balanced in the load balancing
mode using ECMP or Eth-Trunk based on the inner field in MPLS packets.
● Run user-defined ethernet-over-mpls [ dot1q-tagtag-number ] { inner-
sipsip-offsetsip-nybble-number | inner-dipdip-offsetdip-nybble-number } *
Load balancing based on the inner IP address of VPLS packets is configured
on the outbound Eth-Trunk on the transit node.
● Run user-defined ethernet-over-mpls { inner-ip | inner-ipv6 }
Load balancing based on the inner IP address of VPLS packets is configured
on the outbound Eth-Trunk on the PE node.
NOTE
– This command does not take effect when GRE and IP-in-IP packets are load
balanced based on the outer header.
– Only CE6870EI Supports this command.
● Run eth-trunk { src-interface | seedseed-data | universal-iduniversal-id |
hash-modehash-mode-id } *
An Eth-Trunk load balancing mode is configured in the specified load
balancing profile.
NOTE
----End
Follow-up Procedure
● Configure simulated calculation of an Eth-Trunk outbound interface.
Run the display load-balance forwarding-path unicast interface eth-trunk
trunk-id src-interface interface-type interface-number { ethtype ethtype-
number | vlan vlan-id | [ [ src-ip src-ip-data | dst-ip dst-ip-data ] * | [ src-ipv6
src-ipv6-data | dst-ipv6 dst-ipv6-data | flow-label label-data ] * ] | src-mac
src-mac-data | dst-mac dst-mac-data | protocol { protocol-number | icmp |
igmp | ip | ospf | tcp [ l4-src-port src-port-data | l4-dst-port dst-port-data ] *
| udp [ l4-src-port src-port-data | l4-dst-port dst-port-data ] * } } * slot slot-id
command to configure simulated calculation of an Eth-Trunk outbound
interface after the 5-tuple information, source MAC address, and destination
address are specified.
● Verify the configuration.
Run the display port forwarding-path { src-ip src-ip-data | dst-ip dst-ip-data
| src-mac src-mac-data | dst-mac dst-mac-data | protocol { protocol-number |
gre | icmp | igmp | ip | ipinip | ospf | tcp [ l4-src-port src-port-data | l4-dst-
port dst-port-data ] * | udp [ l4-src-port src-port-data | l4-dst-port dst-port-
data ] * } } * [ enhanced ] command to check the outbound interface of
packets that contain specified 5-tuple information, source MAC address, and
destination MAC address.
Run the display port forwarding-path mpls { { src-ip src-ip-data [ ip-mask-
len | source-ip-mask ] | dst-ip dst-ip-data [ ip-mask-len | dst-ip-mask ] } * |
{ src-ipv6 src-ipv6-data [ ipv6-mask-len ] | dst-ipv6 dst-ipv6-data [ ipv6-
mask-len ] } * }{ transit label-number labelnum | ingress | egress label-
number labelnum } command to check the outbound interface of MPLS
packets that contain information such as the inner source IP address,
destination IP address, role, and number of labels.
Context
By default, a CE switch processes received PPPoE packets as common Ethernet
packets. Figure 3-15 shows the format of PPPoE packets. The switch cannot
identify the 5-tuple information in PPPoE packets and performs the hash
algorithm based on the outer Ethernet frame of common Layer 2 packets by
default. Fields in the Layer 2 frames of PPPoE packets are fixed except the source
MAC address, so packets are often unevenly load balanced on an Eth-Trunk. To
improve the load balancing effect, use inner information of PPPoE packets for load
balancing.
NOTE
The CE6881, CE5881, CE6881K, CE6820, CE6863, CE6863K, CE6881E can identify PPPoE
packets and load balance the PPPoE packets without configuring Eth-Trunk load balancing.
Procedure
● Configure a load balancing mode for PPPoE packets on the CE6870EI.
a. Run system-view
By default, the switch load balances PPPoE packets based on the source
MAC address (smac), destination MAC address (dmac), and VLAN ID
(vlan).
You can specify session-id and l4-src-port so that the switch load
balances PPPoE packets based on the session ID and transport-layer
source port of PPPoE packets.
c. Run commit
NOTE
Context
A server is often equipped with two or more network adapters. When a server
connects to a switch, one network adapter is used for server management and the
other network adapters are used for traffic forwarding. In this case, there is much
idle time on the network adapter used for server management and switch
interfaces, and the bandwidth use efficiency is low. To address this issue, upgrade
the server software so that the network adapter used for server management can
be also used for traffic forwarding. When the switch uses an Eth-Trunk to connect
to the server, one Eth-Trunk member interface can be bound to a VLAN for server
management. In addition, service VLANs can be configured on the Eth-Trunk so
that service traffic is load balanced among all Eth-Trunk member interfaces. The
bandwidth use efficiency is therefore improved.
NOTE
NOTE
● This function applies to the scenario where a switch connects to a server, and it can only be
configured on the member interface connecting to the server's management NIC.
● In an Eth-Trunk, only one member interface can be bound to a VLAN or VLANs and one
member interface can be bound to a maximum of eight VLANs. Member interfaces of
multiple Eth-Trunks can be bound to the same VLAN.
● The switch supports a maximum of 256 bound VLANs. If N Eth-Trunk member interfaces
are bound to M VLANs, the maximum value of N multiplied by M is 256.
● After this command is configured, packets from the bound VLAN can be only forwarded
through the bound Eth-Trunk member interface. Non-unicast traffic on the Eth-Trunk can
be only forwarded through the bound Eth-Trunk member interface.
● When an Eth-Trunk member interface is bound to a VLAN or VLANs, VLAN mapping, VLAN
stacking, or MUX VLAN cannot be configured.
● When an Eth-Trunk member interface is bound to a VLAN or VLANs, M-LAG cannot be
configured.
Procedure
Step 1 Run system-view
----End
Procedure
● Run the display eth-trunk [ trunk-id [ interface interface-type interface-
number | verbose ] | brief ] command to check the Eth-Trunk configuration.
● Run the display eth-trunk membership trunk-id command to check
information about Eth-Trunk member interfaces.
● Run the display load-balance profile [ profile-name ] command to check the
load balancing profile of the Eth-Trunk.
● Run the display forward eth-trunk mode command to check the number of
LAGs supported by the device.
NOTE
The CE9860EI, CE6881, CE5881, CE6881K, CE6820, CE6863, CE6863K, and CE6881E do
not support this command.
----End
Context
Typically, the number of LAGs supported by a switch is fixed. However, you can
run the assign forward eth-trunk mode command to flexibly set the number of
LAGs supported by a switch, implementing flexible networking and meeting
diversified service requirements.
NOTE
The number of LAGs supported by the CE9860EI, CE6881, CE5881, CE6881K, CE6820,
CE6863, CE6863K, CE6881E is fixed. The CE6881, CE5881, CE6881K, CE6820, CE6863,
CE6863K, CE6881E do not support a variable number of LAGs.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run assign forward eth-trunk mode { 64 | 128 | 256 | 512 | 1024 }
The number of LAGs supported by the device is set.
For CE6870EI, the number of LAGs supported by the device can be set using the
assign forward eth-trunk mode { 256 | 512 | 1024 } command.
By default, the CE6870EI support 512 LAGs; other models support 128 LAGs.
NOTE
After the assign forward eth-trunk mode command is used to change the number of
LAGs supported by the device, restart the device to make the configuration take effect.
NOTE
Only the CE6857EI, CE6857E, CE6865EI, CE8861EI, and CE8868EI support this command.
----End
Context
Each LAG has one logical interface, that is, an Eth-Trunk. Before configuring link
aggregation, create an Eth-Trunk.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run interface eth-trunk trunk-id
An Eth-Trunk is created and the Eth-Trunk interface view is displayed.
If the specified Eth-Trunk already exists, this command directly displays the Eth-
Trunk interface view.
Advised to create Eth-Trunks in ascending order.
trunk-id defines the Eth-Trunk ID. The value ranges of different models are
different. Table 3-7 lists value ranges of different models.
CE6870EI The value range can be adjusted using the assign forward
eth-trunk mode { 256 | 512 | 1024 } command.
● When 256 is specified, the value is in the range 0 to
255. Each Eth-Trunk allows a maximum of 64 member
interfaces.
● When 512 is specified, the value is in the range 0 to
511. Each Eth-Trunk allows a maximum of 32 member
interfaces. The default value is 512.
● When 1024 is specified, the value is in the range 0 to
1023. Each Eth-Trunk allows a maximum of 16 member
interfaces.
CE6881, CE5881, The value range cannot be adjusted. The value of trunk-id
CE6881K, CE6820, is in the range 0 to 1023. Each Eth-Trunk allows a
CE6863, CE6863K, maximum of 128 member interfaces.
CE6881E
CE8850-64CQ-EI The value range can be adjusted using the assign forward
eth-trunk mode { 32 | 64 | 128 | 256 | 512 | 1024 }
command.
● When 32 is specified, the value is in the range 0 to 31.
Each Eth-Trunk allows a maximum of 64 member
interfaces.
● When 64 is specified, the value is in the range 0 to 63.
Each Eth-Trunk allows a maximum of 32 member
interfaces.
● When 128 is specified, the value is in the range 0 to
127. Each Eth-Trunk allows a maximum of 16 member
interfaces. The default value is 128.
● When 256 is specified, the value is in the range 0 to
255. Each Eth-Trunk allows a maximum of 8 member
interfaces.
● When 512 is specified, the value is in the range 0 to
511. Each Eth-Trunk allows a maximum of 4 member
interfaces.
● When 1024 is specified, the value is in the range 0 to
1023. Each Eth-Trunk allows at most 2 member
interfaces.
Other models: The value range can be adjusted using the assign forward
eth-trunk mode { 64 | 128 | 256 | 512 | 1024 } command.
● When 64 is specified, the value is in the range 0 to 63.
Each Eth-Trunk allows a maximum of 32 member
interfaces.
● When 128 is specified, the value is in the range 0 to
127. Each Eth-Trunk allows a maximum of 16 member
interfaces. The default value is 128.
● When 256 is specified, the value is in the range 0 to
255. Each Eth-Trunk allows a maximum of 8 member
interfaces.
● When 512 is specified, the value is in the range 0 to
511. Each Eth-Trunk allows a maximum of 4 member
interfaces.
● When 1024 is specified, the value is in the range 0 to
1023. Each Eth-Trunk allows at most 2 member
interfaces.
----End
Context
Link aggregation can work in manual load balancing mode, static LACP mode, or
dynamic LACP mode.
In LACP mode, you must manually create an Eth-Trunk and add interfaces to the
Eth-Trunk. However, LACP controls active interfaces through negotiation.
Eth-Trunks in dynamic LACP mode are used only when a Huawei device connects
to a server. For other scenarios, configuring Eth-Trunks in static LACP mode is
recommended to reduce the chances of potential loops.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run interface eth-trunk trunk-id
The Eth-Trunk interface view is displayed.
Step 3 Configure a working mode of the Eth-Trunk.
Configure the static or dynamic LACP mode.
● When the two directly connected devices support LACP, static LACP is
recommended.
Run mode lacp-static
The Eth-Trunk is configured to work in static LACP mode.
Before configuring an Eth-Trunk, ensure that both devices use the same
working mode.
● When a device is directly connected to a server, the dynamic LACP mode is
often used. You can also use the static LACP mode.
Run mode lacp-dynamic
The Eth-Trunk is configured to work in dynamic LACP mode.
----End
Context
You can add member interfaces to an Eth-Trunk in the Eth-Trunk interface view or
member interface view.
Procedure
● Add member interfaces to an Eth-Trunk in the Eth-Trunk interface view.
a. Run system-view
The system view is displayed.
b. Run interface eth-trunk trunk-id
The Eth-Trunk interface view is displayed.
c. (Optional) Run lacp mixed-rate link enable
Interfaces operating at different rates are enabled to forward packets
after the interfaces are added to an Eth-Trunk interface in static LACP
mode.
NOTE
The rate of the interface added to the Eth-Trunk interface is not limited. For
example, 10G and 100G interfaces can be added to the same Eth-Trunk interface.
d. Run trunkport interface-type { interface-number1 [ to interface-
number2 ] } &<1-n>
NOTE
d. Run commit
The configuration is committed.
----End
Follow-up Procedure
When the status of an Eth-Trunk member interface changes, the system sends
traps containing the status change information for you to confirm whether the
device encounters any fault. If you want to know the ID of the Eth-Trunk to which
the member interface belongs, run the trunk-member trap in private-mib
enable command to enable Eth-Trunk member interfaces to send traps through a
private MIB. Traps sent through a private MIB carry the number of the specific
Eth-Trunk interface.
After the trunk-member trap in private-mib enable command is run, traps are
sent through a private MIB, instead of a public MIB. In this case, you can view the
traps only by using the private MIB of Huawei.
After the upper and lower thresholds for the number of active interfaces are set, the range
of the active interface quantity is specified. Depending on the negotiation result of the local
and remote ends on a link, the number of active interfaces can reach the upper threshold
at most. The active interface is selected as follows: select an Actor based on the system
priority and system ID, and then select the active interface based on the port priority and
port ID of the Actor. To configure a specific interface as the active interface, run the lacp
priority command in the interface view to increase the interface priority.
Procedure
Step 1 Run system-view
The system view is displayed.
----End
Context
On an Eth-Trunk interface, you can load balance traffic among member interfaces
according to the weights configured for the member interfaces.
The higher the weight of a member interface, the heavier the load over the
member link. Therefore, you can configure a higher weight for a member interface
so that the member link can carry a heavier load.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run interface interface-type interface-number
The Eth-Trunk member interface view is displayed.
Step 3 Run distribute-weight weight-value
The load balancing weight is configured for the Eth-Trunk member interface.
The default weight of an Eth-Trunk member interface is 1.
----End
Context
An Eth-Trunk supports per-packet load balancing and per-flow load balancing.
● Per-packet load balancing can improve Eth-Trunk bandwidth efficiency to
ensure even load balancing among equal-cost routes, but cannot prevent
packet mis-sequencing. To ensure packet sequencing, confirm that the device
or terminal receiving traffic supports packet reassembly in case of packet mis-
sequencing. Switches support the following per-packet load balancing modes:
– Random mode: The outbound interface of packets is generated randomly
and calculated based on the time when the packets reach the Eth-Trunk.
When the IP address and MAC address of known unicast packets remain
unchanged, configure random per-packet load balancing.
– Round-robin mode: Eth-Trunk member interfaces forward traffic in turn.
When known unicast packets have a similar length, configure round-
robin per-packet load balancing.
● Per-flow load balancing ensures that packets of the same data flow are
forwarded on the same physical link and those of different data flows are
forwarded on different physical links. Table 3-8 lists the load balancing
modes for different types of packets.
IPv4 packets src-ip, dst-ip, l4- src-ip, dst-ip, l4- The load
src-port and l4- src-port, l4-dst- balancing mode
dst-port port, and is relevant to the
protocol packet type and
irrelevant to the
IPv6 packets src-ip, dst-ip, l4- src-ip, dst-ip, packet
src-port, and l4- protocol, l4-src- forwarding
dst-port port, and l4-dst- process.
port
For example,
even if the
system provides
only Layer 2
forwarding for
NOTE
Load balancing is valid only for outgoing traffic; therefore, the load balancing modes for the
interfaces at both ends of the link can be different and do not affect each other.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 (Optional) Run load-balance profile profile-name
A load balancing profile is configured and its view is displayed. profile-name
specifies the name of the load balancing profile.
By default, there is a load balancing profile named default.
Run the following commands as required. You can configure a load balancing
mode for Layer 2 packets, IPv4 packets, IPv6 packets, FCoE, and MPLS packets
respectively.
By default, the switch load balances IPv6 packets based on the source IP
address (src-ip), destination IP address (dst-ip), transport-layer source port
numbers (l4-src-port), and transport-layer destination port numbers (l4-dst-
port).
● Run mpls [ top-label | dst-ip | src-ip | 2nd-label | 3rd-label | 4th-label | 5th-
label | src-interface ] *
A load balancing mode is configured for MPLS packets.
By default, the switch load balances MPLS packets based on the two outer
labels (top-label and 2nd-label).
NOTE
Only the CE6857EI, CE6857E, CE6865EI, CE8861EI, and CE8868EI support 3rd-label,
4th-label, 5th-label, and src-interface. If src-ip or dst-ip is configured, 4th-label or
5th-label cannot be configured.
In V200R005C10 and earlier versions, if 4th-label and 5th-label are configured for
load balancing of MPLS packets in the load balancing profile view or ECMP view, this
configuration takes effect for both Eth-Trunk and ECMP. The load balancing mode
based on src-ip and dst-ip conflicts with that based on 4th-label and 5th-label, and
the last delivered configuration takes effect. Therefore, the effective load balancing
mode is inconsistent with that in the configuration file.
● Run fcoe { dst-fcid | src-fcid } *
A load balancing mode is configured for a stack port or fabric port in the
specified load balancing profile.
By default, a stack port or fabric port load balances packets based on hash-
mode (1) and universal-id (1) in a load balancing profile.
----End
Follow-up Procedure
● Configure simulated calculation of an Eth-Trunk outbound interface.
Configure simulated calculation of an Eth-Trunk outbound interface after
specifying the 5-tuple information, source MAC address, and destination
address.
display load-balance forwarding-path unicast interface eth-trunk trunk-id src-interface interface-
type interface-number { ethtype ethtype-number | vlan vlan-id | [ [ src-ip src-ip-data | dst-ip dst-ip-
data ] * | [ src-ipv6 src-ipv6-data | dst-ipv6 dst-ipv6-data ] * ] | src-mac src-mac-data | dst-mac dst-
mac-data | protocol { protocol-number | icmp | igmp | ip | ospf | tcp [ l4-src-port src-port-data | l4-
dst-port dst-port-data ] * | udp [ l4-src-port src-port-data | l4-dst-port dst-port-data ] * } } * slot slot-
id
Context
An Eth-Trunk uses flow-based load balancing. Per-flow load balancing ensures
that packets of the same data flow are forwarded on the same physical link and
those of different data flows are forwarded on different physical links.
Load balancing is valid only for outgoing traffic; therefore, interfaces at both ends
of the link can use different load balancing modes.
Table 3-9 lists load balancing modes for different types of packets.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run load-balance profile profile-name
A load balancing profile is configured and its view is displayed. profile-name
specifies the name of the load balancing profile.
During Layer 2 forwarding, the switch load balances only IPv4, IPv6, 802.1ah, ARP, and
CFM packets based on eth-type.
During Layer 2 forwarding, an Eth-Trunk configured with Dot1q tunnel, VLAN stacking,
VLL, or VPLS cannot load balance packets based on the VLAN ID.
● Run ip [ src-ip | dst-ip | l4-src-port | l4-dst-port | protocol ] *
To load balance IPv6 packets based on the transport-layer source and destination port
numbers, run the ip [ l4-src-port | l4-dst-port ] * command.
● Run mpls [ 2nd-label | 3rd-label | top-label ] * or mpls [ src-ip | dst-ip | l4-
src-port | l4-dst-port ] *
A load balancing mode is configured for MPLS packets in the specified load
balancing profile.
By default, MPLS packets are load balanced based on top-label, 2nd-label,
and fields in the inner IP header (IPv4/IPv6: src-ip, dst-ip, l4-src-port, and l4-
dst-port).
NOTE
On an IPv6 underlay network, if the IPv6 VXLAN function is enabled and the switch
functions as a transit or egress node on the MPLS network, configurations related to
the hash field in inner information in MPLS packets do not take effect in the load
balancing profile. In this scenario, the mpls inner-type { ipv4 | ipv6 | l2 | any }
command cannot be used to change the load balancing mode for MPLS packets in the
load balancing profile. Instead, you can use the source and destination IP addresses in
inner information in MPLS packets to configure a load balancing mode in the load
balancing profile.
– The mpls [ inner-ip | inner-ipv6 ] * command can be configured only when the
IPv6 VXLAN function is enabled. In addition, this command cannot be used to
configure a load balancing mode for VPLS packets. If the IPv6 VXLAN function is
disabled, the switch automatically deletes the configurations related to the mpls
[ inner-ip | inner-ipv6 ] * command.
– For the CE6870EI, if MPLS packets with four or more labels are received, Eth-Trunk
or ECMP load balancing cannot be implemented based on the inner IP header.
– For the CE6870EI, if the implicit null label is disabled and the outer label is popped
out (for example, ASBR in inter-AS VPN Option B and inter-AS VPN Option C
networking), packets may be unable to be load balanced in the load balancing
mode using ECMP or Eth-Trunk based on the inner field in MPLS packets.
● Run user-defined ethernet-over-mpls [ dot1q-tagtag-number ] { inner-
sipsip-offsetsip-nybble-number | inner-dipdip-offsetdip-nybble-number } *
Load balancing based on the inner IP address of VPLS packets is configured
on the outbound Eth-Trunk on the transit node.
● Run user-defined ethernet-over-mpls { inner-ip | inner-ipv6 }
Load balancing based on the inner IP address of VPLS packets is configured
on the outbound Eth-Trunk on the PE node.
NOTE
and VLAN ID. The items used in load balancing depend on the l2 and
ipv6 commands.
● Run tunnel {outer-header | inner-header}*
Load balancing based on the inner or outer header is configured for tunnel
packets (GRE and IP-in-IP packets) in the specified load balancing profile.
By default, GRE and IP-in-IP packets are load balanced based on both inner
and outer headers.
NOTE
– This command does not take effect when GRE and IP-in-IP packets are load
balanced based on the outer header.
– Only CE6870EI Supports this command.
● Run eth-trunk { src-interface | seedseed-data | universal-iduniversal-id |
hash-modehash-mode-id } *
An Eth-Trunk load balancing mode is configured in the specified load
balancing profile.
NOTE
----End
Follow-up Procedure
● Configure simulated calculation of an Eth-Trunk outbound interface.
Run the display load-balance forwarding-path unicast interface eth-trunk
trunk-id src-interface interface-type interface-number { ethtype ethtype-
Context
By default, a CE switch processes received PPPoE packets as common Ethernet
packets. Figure 3-16 shows the format of PPPoE packets. The switch cannot
identify the 5-tuple information in PPPoE packets and performs the hash
algorithm based on the outer Ethernet frame of common Layer 2 packets by
default. Fields in the Layer 2 frames of PPPoE packets are fixed except the source
MAC address, so packets are often unevenly load balanced on an Eth-Trunk. To
improve the load balancing effect, use inner information of PPPoE packets for load
balancing.
NOTE
The CE6881, CE5881, CE6881K, CE6820, CE6863, CE6863K, CE6881E can identify PPPoE
packets and load balance the PPPoE packets without configuring Eth-Trunk load balancing.
Procedure
● Configure a load balancing mode for PPPoE packets on the CE6870EI.
a. Run system-view
The system view is displayed.
b. Run load-balance eth-trunk pppoe { session-id | l4-src-port { ppp-
address-compression | ppp-protocol-compression | both | none } }
A load balancing mode is configured for PPPoE packets.
By default, the switch load balances PPPoE packets based on the source
MAC address (smac), destination MAC address (dmac), and VLAN ID
(vlan).
You can specify session-id and l4-src-port so that the switch load
balances PPPoE packets based on the session ID and transport-layer
source port of PPPoE packets.
c. Run commit
The configuration is committed.
● Configure a load balancing mode for PPPoE packets on other models
excluding the CE6870EI.
a. Run system-view
The system view is displayed.
b. Run load-balance profile profile-name
The global load balancing profile view is displayed.
By default, the load balancing profile name is default.
c. Run eth-trunk hash-mode 8
The Eth-Trunk load balancing hash algorithm is set to 8.
d. Run quit
The system view is displayed.
e. Run load-balance ecmp
The ECMP view is displayed.
f. Run hashmode 7
The ECMP load balancing hash algorithm is set to 7.
g. Run quit
The system view is displayed.
h. Run load-balance pppoe { session-id | l4-src-port { ppp-address-
compression | ppp-protocol-compression | both | none } }
A load balancing mode is configured for PPPoE packets.
By default, the switch load balances PPPoE packets based on the source
MAC address (smac) and destination MAC address (dmac).
You can specify session-id and l4-src-port so that the switch load
balances PPPoE packets based on the session ID and transport-layer
source port of PPPoE packets.
NOTE
Context
LACP system priorities determine the sequence in which devices at two ends of an
Eth-Trunk select active interfaces to join a LAG. In order for a LAG to be
established, both devices must select the same interfaces as active interfaces. To
achieve this, one device (with a higher priority) is responsible for selecting the
active interfaces. The other device (with a lower priority) then selects the same
interfaces as active interfaces.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run lacp priority priority
The LACP system priority is set.
In priority comparisons, numerically lower values have higher priority. By default,
the LACP system priority is 32768.
The end with a smaller priority value functions as the Actor. If the two ends have
the same priority, the end with a smaller MAC address functions as the Actor.
Step 3 Run commit
The configuration is committed.
----End
Context
In LACP mode, LACP interface priorities are set to prioritize interfaces of the same
device. Interfaces with higher priorities are selected as active interfaces.
Procedure
Step 1 Run system-view
By default, the system selects active interfaces based on interface priorities. This
may lead to low-speed member interfaces with high priorities being selected as
active interfaces, providing less bandwidth for services. To select high-speed
member interfaces as active interfaces, run the lacp select { priority | speed }
command to configure the system to select active interfaces based on the
interface rate.
----End
Context
When devices are connected through Eth-Trunk interfaces in LACP mode, the
device with a higher LACP system priority functions as the LACP Actor. The other
device then selects active member interfaces based on the interface priorities of
the LACP Actor. If the two connected devices have the same LACP system priority,
the LACP system IDs determine the device priorities. To configure an LACP system
ID, run the lacp system-id command. The device with a higher priority then
becomes the LACP Actor. The other device then selects active member interfaces
based on the interface priorities of the LACP Actor.
In this scenario, two Layer 3 Eth-Trunks of the device use the bridge MAC address
by default. When the MAC address is the same, the Layer 3 protocol cannot work.
To ensure that Layer 3 traffic is forwarded normally, configure the MAC address in
Layer 3 mode for at least one Eth-Trunk so that the two Eth-Trunks use different
MAC addresses.
Procedure
Step 1 Run system-view
----End
Context
The LACP preemption function ensures that the interface with the highest LACP
priority will return to functioning as an active interface after recovering from a
fault. If LACP preemption is disabled, the interface cannot become active interface
after it recovers.
The LACP preemption delay is the period that an inactive interface waits before
changing to the active interface. The LACP preemption delay reduces the chances
of unstable data transmission on an Eth-Trunk due to frequent status changes of
some links.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 (Optional) Run lacp ignore aggregation delay
The device is enabled to ignore the value of the Reserved field in received
LACPDUs.
By default, the device identifies the value of the Reserved field in received
LACPDUs.
----End
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run interface eth-trunk trunk-id
The Eth-Trunk interface view is displayed.
Step 3 Run lacp timeout { fast [ user-defined user-defined ] | slow }
The timeout interval at which LACPDUs are received is set.
Context
A server often has two or more NICs. One NIC is used for server management and
service traffic forwarding, other NICs are used for only service traffic forwarding. In
Figure 3-17, a switch is connected to a server through the Eth-Trunk that is added
to VLAN 10 and VLAN 20. VLAN 10 and VLAN 20 are used for forwarding
management packets and service packets, respectively. An independent VLAN
needs to be configured on an Eth-Trunk member interface that connected to the
management NIC of a server, that is, VLAN 10 needs to be bound to the Eth-Trunk
member interface so that the Eth-Trunk member interface can be specially used
for server management. This prevents management packets from being discarded
when management packets are load balanced on different NICs. In addition,
service traffic of VLAN 20 can still be load balanced on all Eth-Trunk member
interfaces, improving the bandwidth usage.
When the Eth-Trunk member interface configured with the independent VLAN is
in Unselect state during LACP negotiation, it cannot forward packets. In this
situation, you can run the trunk member vlan lacp disable command to
configure a flexibly independent VLAN on an Eth-Trunk member interface. When
the Eth-Trunk member interface is in Unselect state, the flexibly independent
VLAN becomes available. The system automatically disables LACP so that the Eth-
Trunk member interface in Unselect state can still forward packets. When the
flexibly independent VLAN becomes available, the Eth-Trunk member interface can
only forward packets in the local VLAN but cannot process traffic from other
VLANs. When the Eth-Trunk member interface enters the Select state, the
independent VLAN becomes available and the Eth-Trunk member interface can
still process traffic from other VLANs.
NOTE
NOTE
● This function applies to the scenario where a switch connects to a server, and it can only be
configured on the member interface connecting to the server's management NIC.
● In an Eth-Trunk, only one member interface can be bound to a VLAN or VLANs and one
member interface can be bound to a maximum of eight VLANs. Member interfaces of
multiple Eth-Trunks can be bound to the same VLAN.
● The switch supports a maximum of 256 bound VLANs. If N Eth-Trunk member interfaces
are bound to M VLANs, the maximum value of N multiplied by M is 256.
● After this command is configured, packets from the bound VLAN can be only forwarded
through the bound Eth-Trunk member interface. Non-unicast traffic on the Eth-Trunk can
be only forwarded through the bound Eth-Trunk member interface.
● When an Eth-Trunk member interface is bound to a VLAN or VLANs, VLAN mapping, VLAN
stacking, or MUX VLAN cannot be configured.
● When an Eth-Trunk member interface is bound to a VLAN or VLANs, M-LAG cannot be
configured.
Procedure
● Bind an independent VLAN to an Eth-Trunk member interface.
a. Run system-view
a. Run system-view
----End
Context
When a server connects to the switch, to improve the reliability, the switch
interface directly connected to the server is added to the Eth-Trunk in static LACP
mode. When the server restarts or goes online and the timeout interval of the Eth-
Trunk that receives LACPDUs is reached, the Eth-Trunk member interface becomes
Down. You can configure the Eth-Trunk member interface in Force Up state so that
the Eth-Trunk member interface can continue to forward service traffic.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run interface interface-type interface-number
The interface view is displayed.
Step 3 Run lacp force-up [ extension ]
The interface is configured in Force Up state.
By default, an interface is not in Force Up state.
After this lacp force-up command is run, the force-up state takes effect only
when all the member interfaces of the Eth-Trunk interface in static LACP mode
time out in receipt of LACPDUs.
When all the Eth-Trunk member interfaces' force-up state takes effect, the
minimum number of active member links configured using the least active-
linknumber link-number command still takes effect, but the maximum number of
active member links configured using the max active-linknumber link-number
command stops taking effect.
To prevent the force-up function from causing packet loss when server and device
interfaces are not correctly connected or the interface is falsely removed from the
Eth-Trunk interface, run the lacp force-up extension command to enable the
extended force-up function on the interface. After the extended force-up function
is enabled, the force-up function can take effect only once. If the interface state
changes from down to up later, the force-up function can take effect once again.
Step 4 Run commit
The configuration is committed.
----End
● If the state of an Eth-Trunk frequently flaps, the LACP protocol status of the
Eth-Trunk also flaps, affecting the Eth-Trunk operations. To resolve this
problem, enable the state flapping suppression function on the Eth-Trunk
working in LACP mode.
● After LACP negotiation succeeds on an Eth-Trunk interface, the interface will
save the source MAC address of the most recently received packet, and will
check the source MAC addresses of packets. If the Eth-Trunk interface receives
a packet with the source MAC address being different from the one which
saved, the Eth-Trunk may be flapped because the once more negotiation.
To prevent an Eth-Trunk interface from alternating between Up and Down,
enable the invalid-MAC-based flapping suppression function on the Eth-Trunk
interface working in LACP mode. After this function is enabled, the Eth-Trunk
interface drops the packet and records the packet information if receiving a
packet with the source MAC address being different from the valid one. In this
manner, the Eth-Trunk interface does not alternate between Up and Down
even if packet flapping occurs.
Procedure
● Enable the state flapping suppression function on an Eth-Trunk.
a. Run system-view
----End
Procedure
● Run the display eth-trunk [ trunk-id [ interface interface-type interface-
number | verbose ] | brief ] command to check the Eth-Trunk configuration.
● Run the display eth-trunk membership trunk-id command to check
information about Eth-Trunk member interfaces.
The CE9860EI, CE6881, CE5881, CE6881K, CE6820, CE6863, CE6863K, and CE6881E do
not support this command.
----End
Context
Determine whether to enable preferentially forwarding of local traffic on an Eth-
Trunk based on actual needs:
Pre-configuration Tasks
Before enabling local preferential forwarding on an Eth-Trunk, complete the
following tasks:
Procedure
Step 1 Run system-view
NOTE
This function is valid only for known unicast packets, and does not work with unknown
unicast packets, broadcast packets, and multicast packets.
Only the CE6863, CE6863K, CE6881E, CE6881K, CE5881 and CE6881 support this function.
The minimum number of active links for enabling preferential forwarding of local
traffic is configured for the Eth-Trunk.
----End
NOTE
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run vlan reserved for l3sub-interface
Reserved VLANs are configured for a Layer 3 sub-interfaces.
NOTE
This command is supported only on the following: CE6857EI, CE6857E, CE6865EI, CE8850EI,
CE8861EI, CE8868EI.
NOTE
By default, the LinkDown alarm (Trap OID: 1.3.6.1.6.1.1.5.3) is generated when the status of a
Layer 2 or Layer 3 sub-interface changes. If a large number of Layer 2 or Layer 3 sub-interfaces
exist on a device, the LinkDown alarm is reported on the sub-interfaces at the interval of several
minutes. In this case, an NMS has to process a large number of interface status change alarms,
which overloads the NMS. To resolve this problem, run the subinterface trap updown disable
command in the system view to disable LinkDown alarm generation on the Layer 2 or Layer 3
sub-interfaces as needed. After this command is run, the LinkDown alarm is no longer
generated on any of the device's Layer 2 or Layer 3 sub-interfaces in case of a status change.
Therefore, exercise caution when running this command.
----End
Prerequisites
Eth-Trunk interfaces have been configured to work in LACP mode.
Context
A device reports an LACP alarm if its Eth-Trunk service in LACP mode fails. To
prevent the device from frequently reporting such alarms, LACP alarm control can
be enabled. After this function is enabled, the device reports
hwLacpNegotiateFailed, hwLacpPartialLinkLoss, hwLacpTotalLinkLoss, or Eth-Trunk
linkdown alarms only when LACP negotiation fails due to the following reasons:
● The device's physical link goes Down.
● LACP negotiation times out.
● LACP determines that packets are looped back.
● LACP determines that the system ID and port key in the LACPDU from the
peer end on the local port are inconsistent with those from the peer end on
the reference port.
Procedure
Step 1 Run system-view
Although a clear alarm is reported, the problem triggering the alarm persists.
----End
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run port forwarding-path path-id pathnum { src-ip src-ip-data [ srcip-mask-len ]
| dst-ip dst-ip-data [ dstip-mask-len ] | protocol { protocolnum | tcp [ l4-src-port
src-port-data | l4-dst-port dst-port-data ] * | udp [ l4-src-port src-port-data | l4-
dst-port dst-port-data ] * } } * statistics precedence precedencenum
A rule for collecting statistics on packets with specified 5-tuple information is
configured.
Step 3 Run commit
The configuration is committed.
----End
Follow-up Procedure
If traffic flows through the interface, you can use the display port forwarding-
path path-id pathnum statistics command to check statistics on the packets that
contain specified 5-tuple information.
Context
NOTICE
Procedure
● Run the reset lacp statistics eth-trunk [ trunk-id [ interface interface-type
interface-number ] ] command to clear statistics on transmitted and received
LACP packets.
● Run the reset port forwarding-path path-id pathnum statistics command
to clear statistics on the packets that contain the specified 5-tuple
information.
----End
Context
During routine maintenance, run the following commands in any view to check
the LAG operating status.
Procedure
● Run the display eth-trunk [ trunk-id [ interface interface-type interface-
number | verbose ] | brief ] command to check the Eth-Trunk configuration.
● Run the display lacp statistics eth-trunk [ trunk-id [ interface interface-type
interface-number ] ] command to check the statistics about LACPDUs sent
and received in LACP mode.
● Run the display interface eth-trunk [ trunk-id ] command to check the Eth-
Trunk status.
● Run the display eth-trunk membership trunk-id command to check
information about member interfaces of an Eth-Trunk.
----End
Context
Multiple physical interfaces can bundle into an Eth-Trunk, and these physical
interfaces are Eth-Trunk member interfaces. Each member interface uses a
specified transmission path. The path-specific service parameters, such as delay,
jitter, and packet loss ratio, are also different. Therefore, you cannot determine
which member interface is faulty when the quality of services on an Eth-Trunk
deteriorates. To resolve this problem, perform a ping test to detect each physical
link, facilitating faulty link locating.
NOTE
The ping test applies to scenarios where two devices are directly connected through an Eth-
Trunk.
Pre-configuration Tasks
Before using ping to monitor the reachability of Layer 3 Eth-Trunk member
interfaces, complete the following task:
● Run the undo portswitch command to configure the Eth-Trunk to work in
Layer 3 mode and configure an IP address for the Layer 3 Eth-Trunk.
NOTE
Procedure
Step 1 Enable the receive end to monitor Layer 3 Eth-Trunk member interfaces.
1. Run the system-view command to enter the system view.
2. Run the trunk member-port-inspect command to enable the receive end to
monitor Layer 3 Eth-Trunk member interfaces.
By default, the receive end is disabled from monitoring Layer 3 Eth-Trunk
member interfaces.
NOTE
The trunk member-port-inspect command takes effect for all Layer 3 Eth-Trunks on
a device. To test the connectivity of Eth-Trunks, disable this function after detection of
Eth-Trunk member interfaces is completed. If this function is not disabled, the device
keeps monitoring Eth-Trunk member interfaces, which consumes a lot of system
resources.
Step 2 Enable the transmit end to monitor Layer 3 Eth-Trunk member interfaces.
1. Run the ping [ ip ] [ -8021p 8021p-value | -a source-ip-address | -c count | -d
| { -f | ignore-mtu } | -h ttl-value | -i interface-type interface-number | -m
time | -p pattern | -q | -r | -ri | -s packetsize | -system-time | -t timeout | { -
tos tos-value | -dscp dscp-value } | -v | -vpn-instance vpn-instance-name ] *
host [ ip-forwarding ] command to enable the transmit end to monitor the
reachability of Layer 3 Eth-Trunk member interfaces.
NOTE
When testing the reachability of Layer 3 Eth-Trunk member interfaces, you must specify
the -a and -i parameters in the ping command. -a and -i indicate the source IP address
and source interface of ICMP Echo Request packets respectively.
break
Reply from 10.1.1.2: bytes=56 Sequence=1 ttl=254 time=2
ms
Reply from 10.1.1.2: bytes=56 Sequence=2 ttl=254 time=1
ms
Reply from 10.1.1.2: bytes=56 Sequence=3 ttl=254 time=2
ms
Reply from 10.1.1.2: bytes=56 Sequence=4 ttl=254 time=1
ms
Reply from 10.1.1.2: bytes=56 Sequence=5 ttl=254 time=2
ms
----End
Networking Requirements
In Figure 3-18, 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. Data transmission and link reliability need 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.
2. Create VLANs and add interfaces to the VLANs.
3. Configure a load balancing mode to ensure that traffic is load balanced
among Eth-Trunk member interfaces.
Procedure
Step 1 Create an Eth-Trunk on SwitchA and SwitchB, and add member interfaces to the
Eth-Trunk.
<HUAWEI> system-view
[~HUAWEI] sysname SwitchA
[*HUAWEI] commit
[~SwitchA] interface eth-trunk 1
[*SwitchA-Eth-Trunk1] mode manual load-balance
[*SwitchA-Eth-Trunk1] trunkport 10ge 1/0/1 to 1/0/3
[*SwitchA-Eth-Trunk1] commit
[~SwitchA-Eth-Trunk1] quit
<HUAWEI> system-view
[~HUAWEI] sysname SwitchB
[*HUAWEI] commit
[~SwitchB] interface eth-trunk 1
[*SwitchB-Eth-Trunk1] mode manual load-balance
[*SwitchB-Eth-Trunk1] trunkport 10ge 1/0/1 to 1/0/3
[*SwitchB-Eth-Trunk1] commit
[~SwitchB-Eth-Trunk1] quit
Step 3 Configure a load balancing mode for Eth-Trunk 1. The configuration of SwitchB is
similar to the configuration of SwitchA, and is not mentioned here.
[~SwitchA] interface eth-trunk 1
[~SwitchA-Eth-Trunk1] load-balance src-dst-mac
[*SwitchA-Eth-Trunk1] commit
[~SwitchA-Eth-Trunk1] quit
NOTE
If the device is CE6870EI, see 3.7.8 (Optional) Configuring a Load Balancing Mode
(CE6870EI).
The preceding command output shows that Eth-Trunk 1 has three member
interfaces: 10GE1/0/1, 10GE1/0/2, and 10GE1/0/3. The member interfaces are all
in Up state. The Operating Status of Eth-Trunk 1 is up.
----End
Configuration Files
● Configuration file of SwitchA
#
sysname SwitchA
#
vlan batch 10 20
#
interface Eth-Trunk1
port link-type trunk
port trunk allow-pass vlan 10 20
load-balance src-dst-mac
#
interface 10GE1/0/1
eth-trunk 1
#
interface 10GE1/0/2
eth-trunk 1
#
interface 10GE1/0/3
eth-trunk 1
#
interface 10GE1/0/4
port link-type trunk
port trunk allow-pass vlan 10
#
interface 10GE1/0/5
port link-type trunk
port trunk allow-pass vlan 20
#
return
Networking Requirements
To improve bandwidth and connection reliability, configure a link aggregation
group (LAG) on two directly connected Switches, as shown in Figure 3-19. The
requirements are as follows:
● Two active links implement load balancing.
● One link functions as the backup link. When a fault occurs on an active link,
the backup link replaces the faulty link to maintain reliable data transmission.
Configuration Roadmap
The configuration roadmap is as follows:
1. Create an Eth-Trunk and configure the Eth-Trunk to work in LACP mode to
implement link aggregation.
2. Add member interfaces to the Eth-Trunk.
3. Set the LACP system priority and determine the Actor so that the Partner
selects active interfaces based on the Actor interface priority.
4. Set the upper threshold for the number of active interfaces to improve
reliability.
5. Set LACP interface priorities and determine active interfaces so that interfaces
with higher priorities are selected as active interfaces.
Procedure
Step 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 is not
mentioned here.
<HUAWEI> system-view
[~HUAWEI] sysname SwitchA
[*HUAWEI] commit
[~SwitchA] interface eth-trunk 1
[*SwitchA-Eth-Trunk1] mode lacp-static
[*SwitchA-Eth-Trunk1] commit
[~SwitchA-Eth-Trunk1] quit
Step 3 Set the system priority on SwitchA to 100 so that SwitchA becomes the Actor.
[~SwitchA] lacp priority 100
[*SwitchA] commit
Step 4 On SwitchA, set the upper threshold for the number of active interfaces to 2.
[~SwitchA] interface eth-trunk 1
[~SwitchA-Eth-Trunk1] lacp max active-linknumber 2
[*SwitchA-Eth-Trunk1] commit
[~SwitchA-Eth-Trunk1] quit
Step 5 Set the LACP interface priority and determine active links on SwitchA.
[~SwitchA] interface 10ge 1/0/1
[~SwitchA-10GE1/0/1] lacp priority 100
[*SwitchA-10GE1/0/1] quit
[*SwitchA] interface 10ge 1/0/2
[*SwitchA-10GE1/0/2] lacp priority 100
[*SwitchA-10GE1/0/2] quit
[*SwitchA] commit
Partner:
--------------------------------------------------------------------------------
ActorPortName SysPri SystemID PortPri PortNo PortKey PortState
10GE1/0/1 32768 0025-9e95-7c11 32768 4 20289 10111100
10GE1/0/2 32768 0025-9e95-7c11 32768 5 20289 10111100
10GE1/0/3 32768 0025-9e95-7c11 32768 6 20289 10100000
[~SwitchB] display eth-trunk 1
Eth-Trunk1's state information is:
Local:
LAG ID: 1 Working Mode: Static
Preempt Delay: Disabled Hash Arithmetic: profile default
System Priority: 32768 System ID: 0025-9e95-7c11
Least Active-linknumber: 1 Max Active-linknumber: 16
Operating Status: up Number Of Up Ports In Trunk: 2
Timeout Period: Slow
--------------------------------------------------------------------------------
ActorPortName Status PortType PortPri PortNo PortKey PortState Weight
10GE1/0/1 Selected 10GE 32768 4 20289 10111100 1
10GE1/0/2 Selected 10GE 32768 5 20289 10111100 1
10GE1/0/3 Unselect 10GE 32768 6 20289 10100000 1
Partner:
--------------------------------------------------------------------------------
ActorPortName SysPri SystemID PortPri PortNo PortKey PortState
10GE1/0/1 100 0025-9e95-7c31 100 1 20289 10111100
10GE1/0/2 100 0025-9e95-7c31 100 2 20289 10111100
10GE1/0/3 100 0025-9e95-7c31 32768 3 20289 10100000
The preceding information shows that the LACP system priority of SwitchA is 100,
which is higher than the LACP system priority of SwitchB. Member interfaces
10GE1/0/1 and 10GE1/0/2 become the active interfaces and are in Selected state.
Interface 10GE1/0/3 is in Unselect state. Two links are active and work in load
balancing mode, and one link is the backup link.
----End
Configuration Files
● Configuration file of SwitchA
#
sysname SwitchA
#
lacp priority 100
#
interface Eth-Trunk1
mode lacp-static
lacp max active-linknumber 2
#
interface 10GE1/0/1
eth-trunk 1
lacp priority 100
#
interface 10GE1/0/2
eth-trunk 1
lacp priority 100
#
interface 10GE1/0/3
eth-trunk 1
#
return
Networking Requirements
In Figure 3-20, ServerA is directly connected to SwitchA through an Eth-Trunk in
static LACP mode. ServerB (file server) connected to SwitchA stores ServerA's
network adapter configuration. After ServerA restarts, its configuration is lost and
SwitchA must obtain the configuration from ServerB. SwitchA cannot perform
negotiation with ServerA because ServerA has lost its Eth-Trunk configuration. In
addition, SwitchA's Eth-Trunk cannot go Up and therefore is unable to forward
data.
You can configure the Eth-Trunk on SwitchA to work in dynamic LACP mode.
When LACP negotiation fails, SwitchA can forward packets at Layer 2 through
member interfaces. Therefore, ServerA can successfully obtain the configuration
from ServerB. After ServerA obtains the configuration, an Eth-Trunk in LACP mode
is established. Devices at both ends of the Eth-Trunk send LACPDUs for
negotiation.
Configuration Roadmap
The configuration roadmap is as follows:
1. Configure the Eth-Trunk on SwitchA to work in dynamic LACP mode, and add
Ethernet physical interfaces to the Eth-Trunk to implement link aggregation.
2. Set the upper threshold for the number of active interfaces to improve
reliability.
3. Set LACP interface priorities and determine active interfaces so that interfaces
with higher priorities are selected as active interfaces.
Procedure
Step 1 Configure the Eth-Trunk on SwitchA to work in dynamic LACP mode and add
Ethernet physical interfaces to the Eth-Trunk.
<HUAWEI> system-view
[~HUAWEI] sysname SwitchA
[*HUAWEI] commit
[~SwitchA] interface eth-trunk 1
[*SwitchA-Eth-Trunk1] mode lacp-dynamic
[*SwitchA-Eth-Trunk1] quit
[*SwitchA] interface 10ge 1/0/1
[*SwitchA-10GE1/0/1] eth-trunk 1
[*SwitchA-10GE1/0/1] quit
[*SwitchA] interface 10ge 1/0/2
[*SwitchA-10GE1/0/2] eth-trunk 1
[*SwitchA-10GE1/0/2] quit
[*SwitchA] interface 10ge 1/0/3
[*SwitchA-10GE1/0/3] eth-trunk 1
[*SwitchA-10GE1/0/3] quit
[*SwitchA] commit
Step 2 On SwitchA, set the upper threshold for the number of active interfaces to 2.
[~SwitchA] interface eth-trunk 1
[~SwitchA-Eth-Trunk1] lacp max active-linknumber 2
[*SwitchA-Eth-Trunk1] quit
[*SwitchA] commit
Step 3 Set LACP interface priorities and determine active links on SwitchA.
[~SwitchA] interface 10ge 1/0/1
[~SwitchA-10GE1/0/1] lacp priority 100
[*SwitchA-10GE1/0/1] quit
[*SwitchA] interface 10ge 1/0/2
[*SwitchA-10GE1/0/2] lacp priority 100
[*SwitchA-10GE1/0/2] quit
[*SwitchA] commit
Partner:
--------------------------------------------------------------------------------
# After SwitchA receives LACPDUs from ServerA and link aggregation negotiation
between SwitchA and ServerA succeeds, run the display eth-trunk command on
SwitchA to check Eth-Trunk information. The command output shows Eth-Trunk
information, such as Eth-Trunk ID (1) and working mode (dynamic LACP mode).
10GE1/0/1 and 10GE1/0/2 are active interfaces and in Selected state, and
10GE1/0/3 is in Unselect state.
[~SwitchA] display eth-trunk 1
Eth-Trunk1's state information is:
Local:
LAG ID: 1 Working Mode: Dynamic
Preempt Delay: Disabled: Hash Arithmetic: profile default
System Priority: 32768 System ID: 0025-9e95-7c11
Least Active-linknumber: 1 Max Active-linknumber: 2
Operating Status: up Number Of Up Ports In Trunk: 2
Timeout Period: Slow
--------------------------------------------------------------------------------
ActorPortName Status PortType PortPri PortNo PortKey PortState
Weight
10GE1/0/1 Selected 10GE 100 0 321 10111100 1
10GE1/0/2 Selected 10GE 100 1 321 10111100 1
10GE1/0/3 Unselect 10GE 32768 2 321 10100000
1
Partner:
--------------------------------------------------------------------------------
ActorPortName SysPri SystemID PortPri PortNo PortKey
PortState
10GE1/0/1 32768 0025-9e95-7c31 32768 0 321
10111100
10GE1/0/2 32768 0025-9e95-7c31 32768 1 321
10111100
10GE1/0/3 32768 0025-9e95-7c31 32768 2 321 10100000
----End
Configuration Files
Configuration file of SwitchA
#
sysname SwitchA
#
interface Eth-Trunk1
mode lacp-dynamic
lacp max active-linknumber 2
#
interface 10GE1/0/1
eth-trunk 1
lacp priority 100
#
interface 10GE1/0/2
eth-trunk 1
lacp priority 100
#
interface 10GE1/0/3
eth-trunk 1
#
return
Networking Requirements
As shown in Figure 3-21, SwitchB and SwitchC are connected through stack cables
to increase the total capacity of devices. The two switches functions as a logical
switch. SwitchB functions as the master switch and SwitchC as the backup switch.
To implement backup between devices and improve reliability, physical interfaces
on the two switches are added to an Eth-Trunk. Traffic from two VLANs, VLAN 2
and VLAN 3, is forwarded through both the two interfaces 10GE1/0/1 and
10GE1/0/2 when the network runs properly. This provides high bandwidth use
efficiency between devices and low traffic forwarding efficiency.
To improve traffic forwarding efficiency, each interface should only forward traffic
from one VLAN (in this example, 10GE1/0/1 forwards traffic from VLAN 2 and
10GE1/0/2 forwards traffic from VLAN3). To achieve this goal, configure the Eth-
Trunk to preferentially forward local traffic.
Figure 3-21 Preferentially forwarding local traffic through the local member
interface
Configuration Roadmap
The configuration roadmap is as follows:
1. Create an Eth-Trunk to implement link aggregation.
2. Add member interfaces to the Eth-Trunk.
3. Enable the Eth-Trunk to preferentially forward local traffic so that traffic is
forwarded by member interfaces on the local device.
4. Configure Layer 2 forwarding to implement Layer 2 connectivity.
Procedure
Step 1 Create an Eth-Trunk and specify the allowed VLANs.
# Configure the stack. In this example, SwitchB is the master switch.
<HUAWEI> system-view
[~HUAWEI] sysname SwitchB
[*HUAWEI] commit
[~SwitchB] vlan batch 2 3
[*SwitchB] interface eth-trunk 1
[*SwitchB-Eth-Trunk1] port link-type trunk
[*SwitchB-Eth-Trunk1] port trunk allow-pass vlan 2 3
[*SwitchB-Eth-Trunk1] commit
[~SwitchB-Eth-Trunk1] quit
# Configure SwitchA.
<HUAWEI> system-view
[~HUAWEI] sysname SwitchA
[*HUAWEI] commit
[~SwitchA] vlan batch 2 3
[*SwitchA] interface eth-trunk 1
[*SwitchA-Eth-Trunk1] port link-type trunk
[*SwitchA-Eth-Trunk1] port trunk allow-pass vlan 2 3
[*SwitchA-Eth-Trunk1] commit
[~SwitchA-Eth-Trunk1] quit
# Configure SwitchA.
[~SwitchA] interface 10GE 1/0/1
[~SwitchA-10GE1/0/1] eth-trunk 1
[*SwitchA-10GE1/0/1] quit
[*SwitchA] interface 10GE 1/0/2
[*SwitchA-10GE1/0/2] eth-trunk 1
[*SwitchA-10GE1/0/2] quit
[*SwitchA] commit
Step 3 In the stack, configure the Eth-Trunk to preferentially forward local traffic.
[~SwitchB] interface eth-trunk 1
[~SwitchB-Eth-Trunk1] undo local-preference disable
[*SwitchB-Eth-Trunk1] commit
[~SwitchB-Eth-Trunk1] quit
# Configure SwitchD.
<HUAWEI> system-view
[~HUAWEI] sysname SwitchD
[*HUAWEI] commit
[~SwitchD] vlan 2
[*SwitchD-vlan2] quit
[*SwitchD] interface 10GE 1/0/1
[*SwitchD-10GE1/0/1] port link-type trunk
[*SwitchD-10GE1/0/1] port trunk allow-pass vlan 2
[*SwitchD-10GE1/0/1] quit
[*SwitchD] interface 10GE 1/0/2
[*SwitchD-10GE1/0/2] port link-type trunk
[*SwitchD-10GE1/0/2] port trunk allow-pass vlan 2
[*SwitchD-10GE1/0/2] quit
[*SwitchD] commit
# Configure SwitchE.
<HUAWEI> system-view
[~HUAWEI] sysname SwitchE
[*HUAWEI] commit
[~SwitchE] vlan 3
[*SwitchE-vlan3] quit
[*SwitchE] interface 10GE 1/0/1
[*SwitchE-10GE1/0/1] port link-type trunk
[*SwitchE-10GE1/0/1] port trunk allow-pass vlan 3
[*SwitchE-10GE1/0/1] quit
[*SwitchE] interface 10GE 1/0/2
[*SwitchE-10GE1/0/2] port link-type trunk
[*SwitchE-10GE1/0/2] port trunk allow-pass vlan 3
[*SwitchE-10GE1/0/2] quit
[*SwitchE] commit
----End
Configuration Files
● Configuration file of the stack
#
sysname SwitchB
#
vlan batch 2 to 3
#
interface Eth-Trunk1
port link-type trunk
port trunk allow-pass vlan 2 to 3
#
interface 10GE1/0/1
eth-trunk 1
#
interface 10GE1/0/2
port link-type trunk
Networking Requirements
In Figure 3-22, DeviceA is dual-homed to DeviceB and DeviceC. The Eth-Trunk in
LACP mode is deployed on DeviceA, and its member interfaces are connected to
10GE1/0/1 and 10GE1/0/2 of DeviceB and DeviceC. 10GE1/0/1 and 10GE1/0/2 use
the same rate and duplex mode. Traffic needs to be load balanced on the two
devices.
Configuration Roadmap
The configuration roadmap is as follows:
1. Create Eth-Trunk 1 in static LACP mode on DeviceA, DeviceB, and DeviceC and
add member interfaces to Eth-Trunk 1 to implement link aggregation.
2. Configure the same LACP system ID on DeviceB and DeviceC.
3. Configure the same LACP system priority on DeviceB and DeviceC.
4. Configure number of Eth-Trunk member interfaces on DeviceC to increase by
32768 to prevent repeated numbers of Eth-Trunk member interfaces in LACP
mode on DeviceB and DeviceC.
Procedure
Step 1 Create Eth-Trunk 1 in LACP mode on DeviceA, DeviceB, and DeviceC and add
member interfaces to Eth-Trunk 1.
<HUAWEI> system-view
[~HUAWEI] sysname DeviceA
[*HUAWEI] commit
[~DeviceA] interface eth-trunk 1
[*DeviceA-Eth-Trunk1] mode lacp-static
[*DeviceA-Eth-Trunk1] trunkport 10ge 1/0/1 to 1/0/4
[*DeviceA-Eth-Trunk1] commit
[~DeviceA-Eth-Trunk1] quit
<HUAWEI> system-view
[~HUAWEI] sysname DeviceB
[*HUAWEI] commit
[~DeviceB] interface eth-trunk 1
Step 3 Set the LACP system priority on DeviceB and DeviceC to 100.
[~DeviceB] lacp priority 100
[*DeviceB] commit
[~DeviceC] lacp priority 100
[*DeviceC] commit
Partner:
--------------------------------------------------------------------------------
ActorPortName SysPri SystemID PortPri PortNo PortKey PortState
10GE1/0/1 100 00e0-cf00-0000 32768 32769 321 10111100
10GE1/0/2 100 00e0-cf00-0000 32768 32770 321 10111100
10GE1/0/1 100 00e0-cf00-0000 32768 4 321 10111100
10GE1/0/2 100 00e0-cf00-0000 32768 5 321 10111100
[~DeviceB] display eth-trunk 1
Eth-Trunk1's state information is:
Local:
LAG ID: 1 Working Mode: Static
Preempt Delay: Disabled Hash Arithmetic: profile default
System Priority: 100 System ID: 00e0-cf00-0000
Least Active-linknumber: 1 Max Active-linknumber: 32
Operating Status: up Number Of Up Ports In Trunk: 2
Timeout Period: Slow
--------------------------------------------------------------------------------
ActorPortName Status PortType PortPri PortNo PortKey PortState Weight
10GE1/0/1 Selected 10GE 32768 4 321 10111100 1
10GE1/0/2 Selected 10GE 32768 5 321 10111100 1
Partner:
--------------------------------------------------------------------------------
ActorPortName SysPri SystemID PortPri PortNo PortKey PortState
10GE1/0/3 100 e468-a356-0cb1 32768 4 321 10111100
10GE1/0/4 100 e468-a356-0cb1 32768 2 321 10100010
[~DeviceC] display eth-trunk 1
Eth-Trunk1's state information is:
Local:
LAG ID: 1 Working Mode: Static
Preempt Delay: Disabled Hash Arithmetic: profile default
System Priority: 100 System ID: 00e0-cf00-0000
Least Active-linknumber: 1 Max Active-linknumber: 16
Operating Status: up Number Of Up Ports In Trunk: 2
Timeout Period: Slow
--------------------------------------------------------------------------------
ActorPortName Status PortType PortPri PortNo PortKey PortState Weight
10GE1/0/1 Selected 10GE 32768 32769 321 10111100 1
10GE1/0/2 Selected 10GE 32768 32770 321 10111100 1
Partner:
--------------------------------------------------------------------------------
ActorPortName SysPri SystemID PortPri PortNo PortKey PortState
10GE1/0/1 100 e468-a356-0cb1 32768 3 321 10111100
10GE1/0/2 100 e468-a356-0cb1 32768 1 321 10100010
The preceding information shows that the value of Operating Status on each
device is up, negotiation of Eth-Trunk 1 is successful. Member interfaces on
DeviceB and DeviceC are active interfaces in Selected state, member interfaces of
DeviceB and DeviceC can load balance traffic. The PortNo parameter on DeviceC
indicates that the numbers of Eth-Trunk member interfaces on DeviceC to increase
by 32768.
----End
Configuration Files
● DeviceA configuration file
#
sysname DeviceA
#
interface Eth-Trunk1
mode lacp-static
#
interface 10GE1/0/1
eth-trunk 1
#
interface 10GE1/0/2
eth-trunk 1
#
interface 10GE1/0/3
eth-trunk 1
#
interface 10GE1/0/4
eth-trunk 1
#
return
● DeviceB configuration file
#
sysname DeviceB
#
lacp priority 100
#
interface Eth-Trunk1
mode lacp-static
lacp system-id 00e0-cf00-0000
#
interface 10GE1/0/1
eth-trunk 1
#
interface 10GE1/0/2
eth-trunk 1
#
return
Procedure
1. Run the display eth-trunk command to check whether the load balancing
mode of the Eth-Trunk meets networking requirements. For example, source
or destination IP address-based load balancing is not recommended in Layer 2
networking.
2. Run the load-balance command to set an appropriate load balancing mode.
NOTE
You can set the load balancing mode based on traffic models. When a parameter of
traffic changes frequently, you can set the load balancing mode based on this
parameter to ensure that the traffic is load balanced evenly. For example, if IP
addresses of packets change frequently, use the load balancing mode based on dst-ip,
src-ip, or src-dst-ip. If MAC addresses of packets change frequently but IP addresses
are fixed, use the load balancing mode based on dst-mac, src-mac, or src-dst-mac.
Fault Description
SwitchA is configured with link aggregation, but SwitchB is not configured with
link aggregation. As a result, the physical status of the member interface on
SwitchA is Up but the link protocol status is Down.
Procedure
Step 1 Run the display this command on 10GE1/0/1, 10GE1/0/2, and 10GE1/0/3 of
SwitchB. The three interfaces do no join the Eth-Trunk.
If interfaces join the Eth-Trunk, you can view the following configuration in the
command output.
#
interface 10GE1/0/1
eth-trunk 1
#
Step 2 On SwitchB, configure the same link aggregation mode as SwitchA. For details,
see 3.7 Configuring Link Aggregation in Manual Load Balancing Mode or 3.8
Configuring Link Aggregation in LACP Mode.
----End