Notes on Administrative Distance and Metric

Routing protocols uses metrics for calculating best path for a remote network. Distance vector routing protocols use “distance” (usually hop-count) as their metric. Link state protocols utilize some sort of “cost” as their metric. Only routes with the best metric are added to the routing table.

 If multiple equal-metric routes exist to a particular network, most routing protocols will load-balance. If your router is running multiple routing protocols, Administrative Distance is used to determine which routing protocol to trust the most. Routing protocol with Lowest administrative distance wins.


A route with an “unknown” Administrative Distance will never be inserted into the routing table
For example consider a router is configured with two routing protocols OSPF and EIGRP. Since EIGRP has lower AD value of 90 when compared to that of OSPF which is 110, the router chooses the path derived by EIGRP. If  we configure a static route with EIGRP, router chooses static route because its AD value is 1.

The Administrative distance can be configured manually and it can override default administrative distance values.
Changing default administrative distance values

RIP
Router(config)#router rip
Router(config-route)#distance < 220>

EIGRP
Router(config)#router eigrp 111
Router(config-route)#distance eigrp  <55 > <200>  [internal Ad value and external Ad value]

OSPF
Router(config)#router OSPF 100
Router(config-route)#distance < 90>

NOTE : To go back to default administrative distance in above protocols use no distance command

4 comments: