Redistribution Configuration: Step By Step Example

advanced redistribution example

After configuring basic redistribution it is time to take a look at advanced redistribution with using more specific commands. We have an example to explain it deeply step by step…

advanced redistribution example

1) Configure EIGRP and OSPF for the network above and advertise all the networks for every router. Don’t use summarization. Routes never should be advertised to both EIGRP and OSPF domain.
2)
 Implement full, mutual redistribution between OSPF and EIGRP for router 2 and router 3. 10.4.0.0/24 and 10.4.1.0/24 must have a seed metric 100 and OSPF tag 10, 10.4.2.0/24 and 10.4.3.0/24 must have a seed metric 200 and OSPF tag 20. All other subnets advertised to OSPF domain must have a seed metric 300, OSPF tag 30. OSPF routes advertised to EIGRP domain must have a BW=400,DLY=20,RGL=55,LD=1,MTU=1500,TAG=40 .External OSPF routes shouldn’t increase their metrics.
3)
10.4.4.0/24 network shouldn’t reach to OSPF routing domain.

4)Make a filtering using route tags ( to make sure that redistributed routes doesn’t occur loop problem ) 

5)Router 3 has a preferred path to reach 10.1.0.0/24. Make sure that routers prefer this path going over router 2.

 

R1(config)#router ospf 1
R1(config-router)#network 10.0.0.0  0.255.255.255 area 0

R4(config)#router eigrp 100
R1(config-router)#network 10.0.0.0
R1(config-router)#no auto

R2(config)#router ospf 1
R2(config-router)#network 10.1.12.0  0.0.0.255 area 0

R2(config)#router eigrp 100
R2(config-router)#network 10.1.24.0  0.0.0.255
R2(config-router)#network 10.1.22.0  0.0.0.255
R2(config-router)#no auto

Let’s make a “sh ip route” before configuring redistribution :

R2# sh ip route
O 10.1.13.0
C 10.1.12.0
D 10.4.4.0
O 10.1.1.0
D 10.4.2.0

R4# sh ip route
D 10.1.23.0 via 10.1.24.2

R1#sh ip route
C 10.1.13.0
C 10.1.12.0
C 10.1.0.0
R3(config)#router ospf 1
R3(config-router)#network 10.1.13.0.  0.0.0.255
R2(config)#router eigrp 100
R2(config-router)#network 10.1.23.0  0.0.0.255
R2(config-router)#no auto

If a route comes inside Router 2, this route’s exit point is pointed as Router 3 and this route is stopped at router 3 ( tag )

R2(config)# access-list 1 permit 10.4.0.0  0.0.0.255
R2(config)#access-list 1 permit 10.4.1.0  0.0.0.255
R2(config)#access-list 2 permit 10.4.2.0  0.0.0.255
R2(config)#access-list 2 permit 10.4.3.0  0.0.0.255
R2(config)#access-list 3 permit 10.4.4.0  0.0.0.255
R2(config)#route-map EIGRP_TO_OSPF  permit 10

Default sequence number of route-map is 10. If we won’t write more than one route-map, it is ok that we don’t write “permit 10”

R2(config-route-map)#match ip add 1     //  1 refers to matching all ip address with the access-list 1 //
R2(config-route-map)#set metric 100     //  metric value set to 100 //
R2(config-route-map)#set tag 10        //tag value is set to 10 //
R2(config-route-map)#exit
R2(config)#route-map EIGRP_TO_OSPF  permit 20     // 20 is the sequence number //
R2(config-route-map)#match ip add 2
R2(config-route-map)#set metric 200
R2(config-route-map)#set tag 20

R2(config)#route-map EIGRP_TO_OSPF deny 30
R2(config-route-map)#match ip add 3     // Deny everything which is permitted by ip addresses match in access list 3 . This command is used for 10.4.4.0 doesn't reach to OSPF domain //
R2(config)#route-map EIGRP_TO_OSPF  permit 40
R2(config-route-map)#set metric 300
R2(config-route-map)#set tag 30

No match command used because rest of the networks will be set a metric of a 300 and tag 30

redistribute eigrp 100 subnets route-map EIGRP_TO_OSPF

All this commands above should be configured on router 3 too !

R1# sh ip route
O E2 10.4.2.0 [110/200]
O E2 10.4.3.0 [110/200]
O E2 10.4.0.0 [110/100]
..
O E2 10.1.24.0 [110/300]
O E2 10.1.23.0 [110/300]

We can see the metric values by “sh ip route” command. If you want to see the tag values too you can use “sh ip route 10.4.0.0” command

R1# sh ip route



..
O E2 10.4.0.0 via 10.1.13.3
              via 10.1.12.2

Because of router 2 and router 3 redistributes these networks with same metric, load balancing occurs between 10.1.13.3 and 10.1.12.2

O E2 10.4.1.0 via 10.1.13.3
         10.4.1.0 via 10.1.12.2

R2(config)#route-map OSPF_TO_EIGRP
R2(config-route-map)#set metric 400 20 255 1 1500
R2(config-route-map)#set tag 40
ex

R2(config)#router eigrp 100
R2(config-router)#redistribue ospf 1 route-map OSPF_TO_EIGRP

// Same configs should be made on Router 3 //

OSPF -> EIGRP is using tag=40
EIGRP-> OSPF  tag=40 will be blocked.

EIGRP->OSPF is using tag=10,20,30
OSPF->EIGRP  tag=10,20,30 will be blocked.

R2(config)#route-map EIGRP_TO_OSPF deny 5

We told that default sequence number is 10.  Because of we attached a sequence number 5 , which is lower than 10 , route-map will check these commands first ! That’s the trick !

R2(config-router)#match tag 40
R2(config)#route-map OSPF_TO_EIGRP deny 5
R2(config-router)#match tag 10 20 30       // Tag 10 or 20 or 30 //

Same configs should be made on Router 3…

One thought on “Redistribution Configuration: Step By Step Example

  1. Ow are you.
    I don’t understand this 2 first command to the router 1
    R1(config)#router ospf 1
    R1(config-router)#network 10.0.0.0 0.255.255.255 area 0

Leave a Reply

Your email address will not be published. Required fields are marked *