Enabling GR for BGP Peers

After the GR capability is configured for a BGP peer, a BGP speaker can negotiate with the peer to establish a BGP session with the GR capability.

Usage Scenario

A BGP restart causes re-establishment of all the involved peer relationships, resulting in traffic interruption. Enabling GR globally can prevent traffic interruption. However, this will disconnect all the BGP peer relationships on a device and cause the device to re-negotiate the GR capability with these peers, which affects all the BGP-dependent services running on the live network. To prevent this problem, you can enable GR on a BGP speaker for specified BGP peers so that the BGP speaker negotiates the GR capability only with the specified peers. If negotiation succeeds, BGP connections are established between the BGP speaker and specified peers.

Procedure

  1. Run system-view

    The system view is displayed.

  2. Run bgp as-number

    The BGP view is displayed.

  3. Run peer { ipv4-address | group-name } capability-advertise graceful-restart

    GR is enabled for a specified peer or peer group, and the device is enabled to advertise the GR capability to the peer or peer group.

    If a specified peer does not support GR, you can run the peer ipv4-address local-graceful-restart enable command to enable local GR for the specified peer.

    If a specified peer group has peers that do not support GR, run both peer group-name capability-advertise graceful-restart and peer group-name local-graceful-restart enable commands.

  4. (Optional) Run peer { ipv4-address | group-name } graceful-restart timer restart time-value

    The maximum duration is set for the specified peer or peer group to wait for the BGP peer relationship to be reestablished with the device, and the device is configured to advertise the maximum duration to the specified peer or peer group.

    If a specified peer does not support GR, run the peer ipv4-address local-graceful-restart timer restart restart-time command to set the maximum duration for the device to wait for its BGP peer relationship to be reestablished with the specified peer.

    If a specified peer group has peers that do not support GR, run both peer group-name graceful-restart timer restart time-value and peer group-name local-graceful-restart timer restart restart-time commands.

  5. (Optional) Run peer { ipv4-address | group-name } graceful-restart peer-reset

    The device is enabled to use the GR mode to reset the BGP connection with the specified peer or each peer in the specified group.

    Currently, BGP does not support dynamic capability negotiation. Therefore, each time a BGP capability is changed or a new BGP capability is enabled, a BGP speaker tears down the existing sessions with the affected peers and renegotiates BGP capabilities with these peers. For example, a BGP speaker has established a BGP IPv4 unicast peer relationship with a peer, and the IPv4 service is running properly. A change of BGP capability causes the BGP IPv4 unicast peer relationship to be reestablished, affecting the normal running of the IPv4 service. To address this issue, run the peer { ipv4-address | group-name } graceful-restart peer-reset command.

  6. (Optional) Run peer { ipv4-address | group-name } graceful-restart timer wait-for-rib time-value

    The maximum duration is set for the device to wait for the End-of-RIB flag from the specified peer or peer group.

    If a specified peer does not support GR, run the peer ipv4-address local-graceful-restart timer wait-for-rib wfrtime command to set the maximum duration for the device to wait for the End-of-RIB flag from the peer.

    If a specified peer group has peers that do not support GR, run both peer group-name graceful-restart timer wait-for-rib time-value and peer group-name local-graceful-restart timer wait-for-rib wfrtime commands.

  7. Run commit

    The configuration is committed.

Verifying the Configuration

  • Run the display bgp peer verbose command to check the BGP GR status.
  • Run the display bgp graceful-restart status command to check GR information on the BGP speaker.
  • Run the display bgp local-graceful-restart status command to check information about local GR on the BGP speaker.
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >