Controlling Routing with AD CCNP BSCI

Controlling Routing with AD
CCNP BSCI
[ 54 ] CCNP BSCI Quick Reference
RIP OSPF
10.1.1.0
R2
R4
R3
R1
R2 redistributes its RIP routes into OSPF. These routes inherit OSPF’s AD
when they are advertised to R4. R4 then advertises them to R3 as OSPF
routes.
R3 now knows about the 10.1.1.0 network from two routing processes: RIP,
with an AD of 120, and OSPF, with an AD of 110. The shortest path is the
RIP route through R1. The OSPF path goes through R4 and R2, and then to
R1—a much longer path. But, based on AD, R3 puts the OSPF path in its
routing table.
To prevent this, increase the AD of the redistributed RIP routes when OSPF
advertises them. Note that this doesn’t change all OSPF routes, just the ones
learned from RIP. The commands given on R2 (the router doing the initial
redistribution) are shown in the following:
Router(config)#access-list 10 permit 10.1.1.0
!
Router(config)#router ospf 1
Router(config-router)#redistribute rip subnets
Router(config-router)#distance 125 0.0.0.0 255.255.255.255 10
The AD is increased to 125 for routes from all neighbors, if they match the
network permitted in access list 10. Now R3 hears about the 10.1.1.0 network
from RIP with an AD of 120, and from OSPF with an AD of 125. The RIP
route is put into the routing table based on its lower AD.