< Home

port link-flap protection enable

Function

The port link-flap protection enable command enables link flapping protection on an interface.

The undo port link-flap protection enable command disables link flapping protection on an interface.

By default, link flapping protection is disabled on an interface.

Format

port link-flap protection enable

undo port link-flap protection enable

Parameters

None

Views

Ethernet interface view, GE interface view, XGE interface view, MultiGE interface view, 25GE interface view, 40GE interface view, 100GE interface view, port group view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

Link flapping occurs when the physical status of an interface frequently alternates between Up and Down due to network flapping or network cable faults. Link flapping causes frequent network topology changes and affects user communication. For example, two links work in primary/backup mode. If the interface of the primary link experiences frequent Up/Down transitions, flows are switched between the primary and backup links. Frequent service switchovers increase load of the device and may result in service data loss.

Link flapping protection can solve the problem. You can configure this function to disable an interface that frequently alternates between Up and Down. When the interface is Down, the network topology will not change frequently. In the preceding example, you can configure link flapping protection on the interface of the primary link to prevent frequent topology changes. When the system detects frequent physical status changes on the interface of the primary link, the system directly disables the interface to trigger a primary/backup link switchover. The backup link then steadily transmits services. The link flapping protection function involves the following parameters:
  • Number of link flappings: One link flapping refers to one interface Up/Down transition.
  • Link flapping period: It is a period during which the system counts the number of link flappings.
If the number of link flappings on an interface reaches the threshold within a link flapping period, the system disables the interface and records its status as ERROR DOWN(link-flap), indicating that the interface is Down because of link flappings. By default, after link flapping protection is enabled, an interface goes Down if its status changes five times within 10 seconds.

Follow-up Procedure

  • Run the port link-flap interval interval-value command to set the link flapping interval for the interface.

  • Run the port link-flap threshold threshold-value command to set the number of link flappings for the interface.

  • An interface in Error-down state can be recovered using either of the following methods:
    • Manual recovery: If a few interfaces need to be recovered forcibly, run the shutdown and undo shutdown commands in the interface view. Alternatively, run the restart command in the interface view to restart the interfaces.
    • Automatic recovery: If a large number of interfaces need to be recovered, manual recovery is time consuming and some interfaces may be omitted. You can run the error-down auto-recovery cause link-flap interval interval-value command in the system view to enable automatic interface recovery and set the recovery delay time. An interface in Error-down state automatically recovers when the specified delay time expires.

Example

# Enable link flapping protection on GE0/0/1.

<HUAWEI> system-view
[HUAWEI] interface gigabitethernet 0/0/1
[HUAWEI-GigabitEthernet0/0/1] port link-flap protection enable
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >