No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

Configuration Guide - IP Unicast Routing

CloudEngine 8800, 7800, 6800, and 5800 V200R005C10

This document describes the configurations of IP Unicast Routing, including IP Routing, Static Route, RIP, RIPng, OSPF, OSPFv3, IPv4 IS-IS, IPv6 IS-IS, BGP, Routing Policy, and PBR.
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Configuring the ECMP Load Balancing Mode

Configuring the ECMP Load Balancing Mode

Context

Equal-Cost Multi-Path (ECMP) implements load balancing and link backup. ECMP applies to the network where multiple links to the same destination are available. In the traditional routing technology, packets are forwarded to the destination through one link only; the other links are in backup or inactive state; switching between these links requires a certain period when dynamic routes are used. Different from the traditional routing technology, ECMP can use multiple links to increase transmission bandwidth and transmit data on a faulty link without any delay or packet loss. ECMP is classified into per-flow load balancing and per-packet load balancing. Per-flow load balancing can ensure the packet sequence and ensure that the same data flow is forwarded using the same route and different data flows are forwarded using different routes. Per-packet load balancing can improve ECMP 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 that receives traffic supports packet reassembly in case of packet mis-sequencing.

Per-packet load balancing takes precedence over per-flow load balancing. When both of them are configured, per-packet load balancing takes effect.

In per-packet load balancing, devices support the following load balancing modes:
  • random mode: A route is randomly selected among multiple equal-cost routes to forward packets. When the IP address and MAC address of known unicast packets remain unchanged, configure random per-packet load balancing.
  • round-robin mode: Each equal-cost route, in turn, is used to forward packets. When known unicast packets have the similar length, configure round-robin per-packet load balancing.

The CE5880EI, CE6870EI, CE6875EI, and CE6880EI support only round-robin per-packet load balancing.

The CE6857EI, CE6865EI, CE8850EI, CE8860EI, CE8861EI, and CE8868EI support random per-packet load balancing and round-robin per-packet load balancing. Other switches except those above do not support per-packet load balancing.

In per-flow load balancing, devices support different load balancing modes for different packets, as listed in Table 1-5, Table 1-6, Table 1-7, and Table 1-8.

Table 1-5 Load balancing modes for different packets (CE6870EI and CE6875EI)

Packets (on the Inbound Interface)

Default Load Balancing Mode

Configurable Load Balancing Mode

IPv4 packets

src-ip, dst-ip, l4-src-port, and l4-dst-port

src-ip, dst-ip, l4-src-port, l4-dst-port, and protocol

IPv6 packets

src-ip, dst-ip, l4-src-port, and l4-dst-port

src-ip, dst-ip, l4-src-port, l4-dst-port, and protocol

NOTE:

IPv6 packet load balancing modes, l4-src-port and l4-dst-port are affected by the l4-src-port and l4-dst-port fields of IPv4 packets. That is, when the load balancing modes of IPv4 packets include l4-src-port or l4-dst-port, the l4-src-port or l4-dst-port field also participates in load balancing of IPv6 packets.

TRILL packets

Ingress: Non-IP packets are load balanced based on the inner src-mac, vlan, and dst-mac. IP packets are load balanced based on src-ip, dst-ip, l4-src-port, and l4-dst-port.

src-ip, dst-ip, l4-src-port, l4-dst-port, protocol, vlan, and src-interface

Transit/Egress: Packets are load balanced based on the inner src-mac and dst-mac.

The load balancing mode cannot be configured.

MPLS packets

Transit: top-label, 2nd-label, and fields in the inner IP header (on CE6870EI, IPv4: src-ip and dst-ip or IPv6: src-ip, dst-ip; on CE6875EI, IPv4: src-ip, dst-ip, l4-src-port, and l4-dst-port or IPv6: src-ip, dst-ip, l4-src-port, and l4-dst-port)

Egress: top-label, 2nd-label, and fields in the inner IP header (IPv4: src-ip, dst-ip, l4-src-port, and l4-dst-port or IPv6: src-ip, dst-ip, l4-src-port, and l4-dst-port)

top-label, 2nd-label, 3rd-label, src-ip, dst-ip, l4-src-port, and l4-dst-port

NOTE:
  • On a CE6870EI:
    • On an egress node, the load balancing mode based on fields in the inner IP header (IPv4: src-ip, dst-ip, l4-src-port, and l4-dst-port or IPv6: src-ip, dst-ip, l4-src-port, and l4-dst-port) does not need to be configured, but the fields that participate in load balancing are affected by the load balancing mode configuration of IPv4 and IPv6 packets. If the l4-src-port and l4-dst-port fields are specified in the configured load balancing mode, packets may be unable to be load balanced in the configured load balancing mode. To prevent this problem, cancel the configuration of the l4-src-port and l4-dst-port fields in the load balancing mode of IPv4 packets.
    • On a transit node, the load balancing mode based on fields in the inner IP header (IPv4: src-ip and dst-ip or IPv6: src-ip and dst-ip) does not need to be configured, but the fields that participate in load balancing are affected by the load balancing mode configuration of IPv4 and IPv6 packets. If the mpls [ src-ip | dst-ip | l4-src-port | l4-dst-port ] * command is executed to change the load balancing mode for MPLS packets and the l4-src-port and l4-dst-port fields are specified for load balancing, packets may be unable to be load balanced in the configured load balancing mode. To prevent this problem, run this command again without specifying the l4-src-port and l4-dst-port fields.
  • On a CE6875EI, the load balancing mode based on fields in the inner IP header (IPv4: src-ip, dst-ip, l4-src-port, and l4-dst-port or IPv6: src-ip, dst-ip, l4-src-port, and l4-dst-port) does not need to be configured, but the fields that participate in load balancing are affected by the load balancing mode configuration of IPv4 and IPv6 packets. If the l4-src-port and l4-dst-port fields are specified in the configured load balancing mode, packets may be unable to be load balanced in the configured load balancing mode. To prevent this problem, cancel the configuration of the l4-src-port and l4-dst-port fields in the load balancing mode of IPv4 and MPLS packets.
Table 1-6 Load balancing modes for different packets (only on the CE6880EI and the CE5880EI)

Packets (on the Inbound Interface)

Default Load Balancing Mode

Configurable Load Balancing Mode

IP packets

src-ip, dst-ip, l4-src-port, and l4-dst-port

src-ip, dst-ip, l4-src-port, l4-dst-port, protocol, vlan, src-interface, and dscp

GRE packets, 6over4 packets

Non-IP packets are load balanced based on the inner inner-src-ip, inner-dst-ip, inner-l4-dport, and inner-l4-sport. IP packets are load balanced based on src-ip, dst-ip, l4-src-port, and l4-dst-port.

inner-src-ip, inner-dst-ip, inner-l4-dport, and inner-l4-sport

Table 1-7 Load balancing modes for different packets (only on the CE6857EI, CE6865EI, CE8861EI, and CE8868EI)

Packets (on the Inbound Interface)

Default Load Balancing Mode

Configurable Load Balancing Mode

IPv4 packets

src-ip, dst-ip, l4-src-port, and l4-dst-port

src-ip, dst-ip, l4-src-port, l4-dst-port, protocol, vlan, and src-interface

IPv6 packets

src-ipv6, dst-ipv6, l4-src-port, and l4-dst-port

src-ipv6, dst-ipv6, l4-src-port, l4-dst-port, protocol, vlan, and src-interface

MPLS packets

src-ip, dst-ip, top-label, 2nd-label, and 3rd-label

src-ip, dst-ip, src-interface, top-label, 2nd-label, 3rd-label, 4th-label, and 5th-label

Table 1-8 Load balancing modes for different packets (models excluding the CE5880EI, CE6857EI, CE6865EI, CE6870EI, CE6875EI, CE6880EI, CE8861EI, and CE8868EI)

Packets (on the Inbound Interface)

Default Load Balancing Mode

Configurable Load Balancing Mode

IPv4 packets

src-ip, dst-ip, l4-src-port, and l4-dst-port

src-ip, dst-ip, l4-src-port, l4-dst-port, protocol, vlan, and src-interface

IPv6 packets

src-ipv6, dst-ipv6, l4-src-port, and l4-dst-port

src-ipv6, dst-ipv6, l4-src-port, l4-dst-port, protocol, vlan, and src-interface

TRILL packets

Non-IP packets are load balanced based on the inner src-mac and dst-mac. IP packets are load balanced based on src-ip, dst-ip, l4-src-port, and l4-dst-port.

src-ip, dst-ip, l4-src-port, and l4-dst-port

MPLS packets

src-ip and dst-ip

src-ip, dst-ip, in-label, and out-label

Procedure

  • Configure ECMP load balancing (on the CE6857EI, CE6865EI, CE8861EI, and CE8868EI).

    Based on per-flow:

    1. Run system-view

      The system view is displayed.

    2. Run load-balance ecmp

      The ECMP view is displayed.

    3. You can configure different load balancing modes for different packets. Perform the following operations according to network packet types.

      • Run ipv4 { src-ip | dst-ip | vlan | l4-src-port | l4-dst-port | protocol | src-interface } *

        The load balancing mode is specified for IPv4 packets.

      • Run ipv6 { src-ipv6 | dst-ipv6 | vlan | l4-src-port | l4-dst-port | protocol | src-interface } *

        The load balancing mode is specified for IPv6 packets.

      • Run mpls { src-ip | dst-ip | top-label | 2nd-label | 3rd-label | src-interface } * or mpls { top-label | 2nd-label | 3rd-label | 4th-label | 5th-label | src-interface } *

        The load balancing mode is specified for MPLS packets.

      NOTE:

      If src-ipv6 and dst-ipv6 are specified for ECMP load balancing of IPv6 packets, the switch uses only the low 32 bits of the source and destination IPv6 addresses as the hash fields.

    4. Run hashmodehashmode-id

      The hash algorithm mode used in ECMP load balancing is configured.

      By default, the hash algorithm mode used in ECMP load balancing is 4.

    5. Run local-preference enable

      Local traffic preferential forwarding is enabled.

      By default, local traffic preferential forwarding is disabled.

    6. Run commit

      The configuration is committed.

    Based on per-packet:

    1. Run system-view

      The system view is displayed.

    2. Run load-balance ecmp

      The ECMP view is displayed.

    3. Run load-balance { random | round-robin }

      Random or round-robin per-packet load balancing is configured.

      NOTE:

      If both per-packet load balancing and per-flow load balancing are configured in ECMP, per-packet load balancing takes effect.

    4. Run commit

      The configuration is committed.

  • Configure ECMP load balancing (for the CE6870EI and CE6875EI).
    1. Run system-view

      The system view is displayed.

    2. Run load-balance profileprofile-name

      A load balancing profile is configured and its view is displayed.

    3. Run the following commands as required. You can configure a load balancing mode for IPv4 and IPv6 packets.

      • Run ip [ dst-ip | l4-dst-port | l4-src-port | protocol | src-ip ] *

        The load balancing mode of IPv4 packets is set in the load balancing profile.

      • Run ipv6 [ dst-ip | protocol | src-ip ] *

        The load balancing mode of IPv6 packets is set in the load balancing profile.

        NOTE:

        IPv6 packet load balancing modes, l4-src-port and l4-dst-port are affected by the l4-src-port and l4-dst-port fields of IPv4 packets. That is, when the load balancing modes of IPv4 packets include l4-src-port or l4-dst-port, the l4-src-port or l4-dst-port field also participates in load balancing of IPv6 packets.

      • Run mpls [ 2nd-label | 3rd-label | top-label ] * or mpls [ src-ip | dst-ip | l4-src-port | l4-dst-port ] *

        The load balancing mode of MPLS packets is set in the load balancing profile.

        By default, load balancing of MPLS packets is based on the two outer labels (top-label and 2nd-label) of each packet.

        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 and CE6875EI, 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 and CE6875EI, 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.
        • The mpls [ inner-ip | inner-ipv6 ] * command takes effect only on the CE6875EI.

    4. Run ecmp { src-interface | seed seed-data } *

      The ECMP load balancing mode is set in the enhanced load balancing profile.

      By default, the ECMP load balancing mode is seed.

    5. Run ecmp universal-id universal-id

      The hash algorithm offset of ECMP load balancing is set in the enhanced load balancing profile.

      By default, the hash algorithm offset of ECMP is 1.

    6. Run ecmp hash-modehashmode-id

      The hash algorithm mode used in ECMP load balancing is configured.

      By default, the hash algorithm mode used in ECMP load balancing is 2. Set the hash algorithm mode to 3/4/5 for per-packet load balancing.

    7. Run ecmp local-preference enable

      Local traffic preferential forwarding is enabled.

      By default, local traffic preferential forwarding is disabled.

    8. Run commit

      The configuration is committed.

  • Configure the ECMP load balancing mode (on the CE6880EI and the CE5880EI).
    1. Run system-view

      The system view is displayed.

    2. Run load-balance ecmp

      The ECMP view is displayed.

    3. Run the following commands as required. You can configure a load balancing mode for IP packets.

      • Run ip { src-ip | dst-ip | vlan | l4-src-port | l4-dst-port | protocol | src-interface | dscp } *

        A load balancing mode is configured for IP packets in ECMP.

      • Run ip-tunnel { inner-src-ip | inner-dst-ip | inner-l4-sport | inner-l4-dport } *

        A load balancing mode is configured for GRE packets and 6over4 packets in ECMP.

    4. Run hashmodehashmode-id

      The hash algorithm mode used in ECMP load balancing is configured.

      By default, the hash algorithm mode used in ECMP load balancing is 0. Set the hash algorithm mode to 1 for per-packet load balancing.

    5. Run local-preference enable

      Local traffic preferential forwarding is enabled.

      By default, local traffic preferential forwarding is disabled.

    6. Run commit

      The configuration is committed.

  • Configure ECMP load balancing (on the CE8860EI and the CE8850EI).

    Based on per-flow:

    1. Run system-view

      The system view is displayed.

    2. Run load-balance ecmp

      The ECMP view is displayed.

    3. You can configure different load balancing modes for different packets. Perform the following operations according to network packet types.

      • Run ipv4 { src-ip | dst-ip | vlan | l4-src-port | l4-dst-port | protocol | src-interface } *

        The load balancing mode is specified for IPv4 and TRILL packets.

      • Run ipv6 { src-ipv6 | dst-ipv6 | vlan | l4-src-port | l4-dst-port | protocol | src-interface } *

        The load balancing mode is specified for IPv6 packets.

      • Run mpls { src-ip | dst-ip | src-ipv6 | dst-ipv6 | in-label | out-label }

        The load balancing mode is specified for MPLS packets.

      NOTE:

      If src-ipv6 and dst-ipv6 are specified for ECMP load balancing of IPv6 packets, the switch uses only the low 32 bits of the source and destination IPv6 addresses as the hash fields.

    4. Run hashmodehashmode-id

      The hash algorithm mode used in ECMP load balancing is configured.

      By default, the hash algorithm mode used in ECMP load balancing is 4.

    5. Run local-preference enable

      Local traffic preferential forwarding is enabled.

      By default, local traffic preferential forwarding is disabled.

    6. Run commit

      The configuration is committed.

    Based on per-packet:

    1. Run system-view

      The system view is displayed.

    2. Run load-balance ecmp

      The ECMP view is displayed.

    3. Run load-balance { random | round-robin }

      Random or round-robin per-packet load balancing is configured.

      NOTE:

      If both per-packet load balancing and per-flow load balancing are configured in ECMP, per-packet load balancing takes effect.

    4. Run commit

      The configuration is committed.

  • Configure ECMP load balancing (models excluding the CE5880EI, CE6857EI, CE6865EI, CE6870EI, CE6875EI, CE6880EI, CE8850EI, CE8860EI, CE8861EI, and CE8868EI).
    1. Run system-view

      The system view is displayed.

    2. Run load-balance ecmp

      The ECMP view is displayed.

    3. You can configure different load balancing modes for different packets. Perform the following operations according to network packet types.

      • Run ipv4 { src-ip | dst-ip | vlan | l4-src-port | l4-dst-port | protocol | src-interface } *

        The load balancing mode is specified for IPv4 and TRILL packets.

      • Run ipv6 { src-ipv6 | dst-ipv6 | vlan | l4-src-port | l4-dst-port | protocol | src-interface } *

        The load balancing mode is specified for IPv6 packets.

        The CE6810LI does not support ECMP load balancing for IPv6 packets.

      • Run mpls { src-ip | dst-ip | src-ipv6 | dst-ipv6 | in-label | out-label }

        The load balancing mode is specified for MPLS packets.

        Only the CE7855EI, CE7850EI, CE6860EI, CE6855HI, CE6856HI, CE6851HI, CE6850HI, and CE6850U-HI support ECMP load balancing for MPLS packets.

      NOTE:

      If src-ipv6 and dst-ipv6 are specified for ECMP load balancing of IPv6 packets, the switch uses only the low 32 bits of the source and destination IPv6 addresses as the hash fields.

    4. Run hashmodehashmode-id

      The hash algorithm mode used in ECMP load balancing is configured.

      By default, the hash algorithm mode used in ECMP load balancing is 4.

    5. Run local-preference enable

      Local traffic preferential forwarding is enabled.

      By default, local traffic preferential forwarding is disabled.

    6. Run commit

      The configuration is committed.

  • Configure simulated calculation of an ECMP outbound interface.

    Run display load-balance forwarding-path unicast interface ecmp { vlanvlan-id | src-interfaceinterface-type interface-number | vpn-instancevpn-instance-name | [ [ src-ipsrc-ip-data | dst-ipdst-ip-data ] * | [ src-ipv6src-ipv6-data | dst-ipv6dst-ipv6-data ] * ] | protocol { protocol-number [ l4-src-portsrc-port-data | l4-dst-portdst-port-data ] | icmp | igmp | ip | ospf | tcp [ l4-src-portsrc-port-data | l4-dst-portdst-port-data ] * | udp [ l4-src-portsrc-port-data | l4-dst-portdst-port-data ] * } } *slotslot-id

    Simulated calculation of an ECMP outbound interface is configured after the 5-tuple information, source MAC address, and destination address are specified.

Verifying the Configuration

  • Run the display load-balance forwarding-path unicast interface ecmp { vlan vlan-id | src-interface interface-type interface-number | vpn-instance vpn-instance-name | [ [ src-ip src-ip-data | dst-ip dst-ip-data ] * | [ src-ipv6 src-ipv6-data | dst-ipv6 dst-ipv6-data ] * ] | protocol { protocol-number [ l4-src-port src-port-data | l4-dst-port dst-port-data ] | 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 ECMP outbound interface for IPv4 and IPv6 packets after the 5-tuple information, source MAC address, and destination address are specified.
Translation
Download
Updated: 2019-04-20

Document ID: EDOC1100074760

Views: 57536

Downloads: 63

Average rating:
This Document Applies to these Products
Related Version
Related Documents
Share
Previous Next