distance

To update the routes filtered via route-map at IP routing layer, use the command distance in OSPF Router Configuration Mode. The no form of this command disables the administrative distance (route preference).

distance

distance { <1-255> } { [route-map } { <name(1-20)>] }

no distance

no distance

Parameters

Parameter Type Description
<1-255>   Enter a value for the administrative distance. The distance value (i.e. the preference value) ranges between 1 and 255. The administrative distance (route preference value) can be updated for routes filtered via only one route map. The distance (route preference) should be disassociated for the already associated route map if distance needs to be associated for another route map.
route-map   Enter to configure the name of the Route Map for which the distance value should be enabled and set
<name(1-20)>   Enter a name for the Route Map for which the distance value should be enabled and set. This value is a string with maximum string of 20.

Mode

OSPF Router Configuration Mode

Default

0 (Represents directly connected route)

Prerequisites

This command executes only if OSPF router is enabled

Examples

iS5Comm(config)# router ospf

iS5Comm(config-router)# distance 10 route-map rmap-test