In a previous lesson I explained the basics of Redistribution. Now it’s time to actually configure some redistribution. In this lesson we’ll cover redistribution between OSPF and RIP. This is the topology that we will use:
Let’s start with the redistribution between OSPF and RIP.
First let me show you the router configurations:
R1(config)#router ospf 1
R1(config-router)#network 1.1.1.0 0.0.0.255 area 0
R1(config-router)#network 192.168.12.0 0.0.0.255 area 0
R2(config)#router ospf 1
R2(config-router)#network 192.168.12.0 0.0.0.255 area 0
R2(config)#router rip
R2(config-router)#version 2
R2(config-router)#no auto-summary
R2(config-router)#network 192.168.23.0
R3(config)#router rip
R3(config-router)#version 2
R3(config-router)#network 3.3.3.0
R3(config-router)#network 192.168.23.0
Nothing special here, just OSPF and RIP advertising their networks.
R1#show ip route
Gateway of last resort is not set
C 192.168.12.0/24 is directly connected, FastEthernet0/0
1.0.0.0/24 is subnetted, 1 subnets
C 1.1.1.0 is directly connected, Loopback0
R2#show ip route
Gateway of last resort is not set
C 192.168.12.0/24 is directly connected, FastEthernet0/0
1.0.0.0/32 is subnetted, 1 subnets
O 1.1.1.1 [110/2] via 192.168.12.1, 00:11:05, FastEthernet0/0
3.0.0.0/24 is subnetted, 1 subnets
R 3.3.3.0 [120/1] via 192.168.23.3, 00:00:20, FastEthernet1/0
C 192.168.23.0/24 is directly connected, FastEthernet1/0
R3#show ip route
Gateway of last resort is not set
3.0.0.0/24 is subnetted, 1 subnets
C 3.3.3.0 is directly connected, Loopback0
C 192.168.23.0/24 is directly connected, FastEthernet0/0
You can see router R2 has learned RIP and OSPF information. Time for some redistribution action!
Hi Rene,
I a have doubts about the command line redistribute ospf 1 metric 5, specific on the hop counts. I see you set the number to 5, why shouldn’t I put 2,3 or maybe 7,8 etc.?? Is there a rule in which indicate what number should go there? I have seen in a few textbooks and videos that instructors put “random” numbers there without explaining the implication of using a very high number or low.
Can you please advice?
Thanks
Hi Jose,
When you only have one router that is redistributing something into RIP, it really doesn’t matter what hop count you pick. Just make sure that the hop count never exceeds 15 anywhere in your network or you will have reachability issues (16 is unreachable).
When you have two routers doing redistribution, it’s a different story. When R1 sets a hop count of 1 and R2 sets a hop count of 5 or something else, all routers will prefer the redistributed path through R1 since the hop count is lower.
Does that make sense?
Rene
Hi Emanuel,
Redistribution is used between different routing protocols, for example EIGRP - OSPF or RIP - OSPF. When you run multi-area OSPF, you don’t need redistribution since areas already share certain LSAs.
Rene
Hi Laz,
I need little more help in understanding. in the link you provide it says the following about E1 saying use this when you use multiple ASBR.
//cdn-forum.networklessons.com/uploads/defau
... Continue reading in our forumHi @wilder7bc,
If you redistribute something into OSPF, the E2 route will have a fixed metric, the E1 route will have a metric that increases throughout the network, it’s the same as with normal OSPF routes.
So why do they use E2 vs E1? Let’s look at some examples. Let’s say the red box is OSPF and blue is some other routing protocol.
Scenario 1
//cdn-forum.networklessons.com/uploads/default/original/1X/91fd907c9ef4401fe856bfb120830b63bdb21c4c.png
There is only one router doing redistribution so it doesn’t matter what the metric is…you can only go through R1 if
... Continue reading in our forum