Configuring BGP Next Hop Recursion Based on a Route-Policy

Configuring BGP next hop recursion based on a route-policy prevents traffic loss if routes changes.

Usage Scenario

When BGP routes change, BGP needs to perform route recursion on the BGP routes with indirect next hops. If no route-policies are configured to filter the routes on which a BGP route with an indirect next hop depends for recursion, the BGP route may recurse to an incorrect route, which may cause traffic loss. To address this problem, configure BGP next hop recursion based on a route-policy. If no routes match the route-policy, the BGP route with an indirect next hop is considered unreachable. In this situation, incorrect route recursion and traffic loss are prevented.

Pre-configuration Tasks

Before configuring BGP next hop recursion based on a route-policy, complete the following tasks:

Before configuring a route-policy, ensure that the routes on which BGP routes with indirect next hops depend for recursion will not be filtered out by the route-policy. Otherwise, route recursion fails, and traffic cannot be forwarded.

Procedure

  1. Run system-view

    The system view is displayed.

  2. Run bgp as-number

    The BGP view is displayed.

  3. Run nexthop recursive-lookup { route-policy route-policy-name | route-filter route-filter-name }

    BGP next hop recursion based on a route-policy or route-filter is configured.

    The command does not apply to the routes received from directly connected EBGP peers or LinkLocal peers.

  4. Run commit

    The configuration is committed.

Checking the Configurations

Run the following commands to check the previous configuration.

  • Run the display bgp routing-table network [ mask | mask-length ] command to check detailed information about a specified route in the BGP routing table.

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >