< Home

bestroute igp-metric-ignore

Function

The bestroute igp-metric-ignore command configures BGP to ignore the IGP metric when selecting the optimal route.

The undo bestroute igp-metric-ignore command restores the default configuration.

By default, BGP uses the IGP metric as one of route selection rules.

Format

bestroute igp-metric-ignore

undo bestroute igp-metric-ignore

Parameters

None

Views

BGP view, BGP-IPv4 unicast address family view, BGP-VPN instance IPv4 address family view, BGP-VPNv4 address family view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

On a BGP network, the router often receives multiple routes with the same prefix but different paths from different peers. To forward traffic to that prefix address, BGP needs to select an optimal route from these routes. By default, BGP will compare the IGP metrics of these routes to their BGP next hops and select a route with the smallest IGP metric.

The bestroute igp-metric-ignore command can be run to configure BGP to ignore the IGP metrics in route selection based on customers' routing requirements.

Configuration Impact

After the bestroute igp-metric-ignore command is run, BGP does not compare the IGP metrics of routes to BGP next hops.

Example

# Configure BGP to ignore the IGP metric when selecting the optimal route.

<sysname> system-view
[sysname] bgp 100
[sysname-bgp] ipv4-family unicast
[sysname-bgp-af-ipv4] bestroute igp-metric-ignore
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >