Route redistribution
when we take a route from one
routing protocol and inject that route or distribute it into another routing
protocol. Routers by default only advertise and share routing information
with other routers running the same protocol and in a same AS. If you have 2
routers and one runs EIGRP and the other runs OSPF and you want them to know
about each other’s routes, by default, router do not share routes information
because they are not running the same protocol. Here we need redistribution.
In short- Redistribution is the process of exchanging
routing information between different routing protocols.
You can use redistribution when using multiple protocols,
migrating to a more advance routing, you can use redistribution if you having
mismatch between devices (vendors) or political boundaries.
Note: internal routes are routes advertised within the same
protocol.
External
routes are routes which get redistributed.
To configure redistribution
Router must be running both protocols
Change metric.
RIPv2: HOP COUNTS
OSPF: COST
EIGRP: BW + DELAY + LOAD
+ MTU + RELIABILITY
Configuration redistribution between RIP and EIGRP
Topology:
- configure the interfaces as per the topology, advertise the interfaces with the same protocols defined as per the topology.
- configure Redistribution on R2 and make sure the R1 and R3 exchange the routes using redistribution.
R1#show ip interface brief
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 10.1.1.1 YES manual up up
Serial3/0 1.1.1.1 YES manual up up
R2#show ip interface brief
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 20.1.1.1 YES manual up up
Serial3/0 1.1.1.2 YES manual up up
Serial3/1 2.2.2.1 YES manual up up
R3#show ip interface brief
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 30.1.1.1 YES manual up up
Serial3/1 2.2.2.2 YES manual up up
R1(config)#router rip
R1(config-router)#version 2
R1(config-router)#network 10.0.0.0
R1(config-router)#network 1.0.0.0
R1(config-router)#no auto-summary
R1(config-router)#end
R2(config)#router rip
R2(config-router)#version 2
R2(config-router)#network 1.0.0.0
R2(config-router)#network 20.0.0.0
R2(config-router)#no auto-summary
R2(config-router)#end
R2(config)#router eigrp 100
R2(config-router)#network 2.0.0.0
R2(config-router)#no auto-summary
R2(config-router)#end
R3(config)#router eigrp 100
R3(config-router)#network 30.0.0.0
R3(config-router)#network 2.0.0.0
R3(config-router)#no auto-summary
R3(config-router)#end
R1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
+ - replicated route, % - next hop override
Gateway of last resort is not set
1.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 1.0.0.0/8 is directly connected, Serial3/0
L 1.1.1.1/32 is directly connected, Serial3/0
10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 10.0.0.0/8 is directly connected, FastEthernet0/0
L 10.1.1.1/32 is directly connected, FastEthernet0/0
R 20.0.0.0/8 [120/1] via 1.1.1.2, 00:00:15, Serial3/0
R3#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
+ - replicated route, % - next hop override
Gateway of last resort is not set
2.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 2.0.0.0/8 is directly connected, Serial3/1
L 2.2.2.2/32 is directly connected, Serial3/1
30.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 30.0.0.0/8 is directly connected, FastEthernet0/0
L 30.1.1.1/32 is directly connected, FastEthernet0/0
R2#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
+ - replicated route, % - next hop override
Gateway of last resort is not set
1.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 1.0.0.0/8 is directly connected, Serial3/0
L 1.1.1.2/32 is directly connected, Serial3/0
2.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 2.0.0.0/8 is directly connected, Serial3/1
L 2.2.2.1/32 is directly connected, Serial3/1
R 10.0.0.0/8 [120/1] via 1.1.1.1, 00:00:08, Serial3/0
20.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 20.0.0.0/8 is directly connected, FastEthernet0/0
L 20.1.1.1/32 is directly connected, FastEthernet0/0
D 30.0.0.0/8 [90/2172416] via 2.2.2.2, 00:02:49, Serial3/1
- The above outputs you can see R2 learn thee routes from R1 and R3 (10.0.0.0 and 30.0.0.0) networks respectively but R1 and R3 can't exchange their routes, the reason is both routers running different routing protocols, we need to configure redistribution on router 2 because router is running both the protocol.
R2(config)#router rip
R2(config-router)#redistribute eigrp 100 metric 5
R2(config-router)#exit
R2(config)#router eigrp 100
R2(config-router)#redistribute rip metric 1000 2000 255 100 1500
R2(config-router)#exit
R1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
+ - replicated route, % - next hop override
Gateway of last resort is not set
1.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 1.0.0.0/8 is directly connected, Serial3/0
L 1.1.1.1/32 is directly connected, Serial3/0
R 2.0.0.0/8 [120/5] via 1.1.1.2, 00:00:09, Serial3/0
10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 10.0.0.0/8 is directly connected, FastEthernet0/0
L 10.1.1.1/32 is directly connected, FastEthernet0/0
R 20.0.0.0/8 [120/1] via 1.1.1.2, 00:00:09, Serial3/0
R 30.0.0.0/8 [120/5] via 1.1.1.2, 00:00:09, Serial3/0
R3#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
+ - replicated route, % - next hop override
Gateway of last resort is not set
D EX 1.0.0.0/8 [170/3584000] via 2.2.2.1, 00:03:04, Serial3/1
2.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 2.0.0.0/8 is directly connected, Serial3/1
L 2.2.2.2/32 is directly connected, Serial3/1
D EX 10.0.0.0/8 [170/3584000] via 2.2.2.1, 00:03:04, Serial3/1
D EX 20.0.0.0/8 [170/3584000] via 2.2.2.1, 00:03:04, Serial3/1
30.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 30.0.0.0/8 is directly connected, FastEthernet0/0
L 30.1.1.1/32 is directly connected, FastEthernet0/0