distance (BGP)

Changes the default administrative distances for eBGP, iBGP, and local BGP.

Syntax

distance external-distance internal-distance local-distance
no distance

Parameters

external-distance
eBGP distance. Range is from 1 through 255.
internal-distance
iBGP distance. Range is from 1 through 255.
local-distance
Local BGP4 and BGP4+ distance. Range is from 1 through 255.

Modes

BGP configuration mode

Usage Guidelines

To select one route over another according to the source of the route information, the device can use the administrative distances assigned to the sources. The administrative distance is a protocol-independent metric that IP devices use to compare routes from different sources. Lower administrative distances are preferred over higher ones.

Examples

The following example configures the device to change the administrative distance.

device# configure terminal
device(config)# router bgp
device(config-bgp-router)# distance 100 150 200