< Home

firewall load-balance

Function

The firewall load-balance command configures the load balancing mode for IP packet forwarding in a multi-egress scenario.

Format

firewall load-balance { flow [ hash { destination-ip | destination-port | source-ip | source-port } * ] | packet }

Parameters

Parameter Description Value

flow

Indicates per-flow load balancing.

-

hash { destination-ip | destination-port | source-ip | source-port } *

Indicates the hash algorithm.

  • destination-ip: destination IP address.

  • destination-port: destination port.

  • source-ip: source IP address.

  • source-port: source port.

By default, the device calculates hash values based on source and destination IP addresses.

packet

Indicates per-packet load balancing.

-

Views

System view

Default Level

2: Configuration level

Usage Guidelines

In a multi-egress scenario, when equal-cost routes exist on the device, IP packets are forwarded in per-flow load balancing mode by default. The source and destination IP addresses are used for hash calculation to select an outbound interface.

If the load of multiple links is unbalanced, you may need to configure the source IP address, source port, destination IP address, and destination port as the hash calculation parameters.

Example

# Set the load balancing mode for IP packet forwarding to per-flow load balancing and enable the device to calculate hash values based on source and destination addresses and ports.

<FW> system-view
[FW] firewall load-balance flow hash source-ip source-port destination-ip destination-port
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >