cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2790
Views
0
Helpful
12
Replies

2-way mutual redistribution - OSPF and RIP

mrjdh
Level 1
Level 1

Please, someone tell me I'm not going mad here...

I have a 4-router setup, all running 15.2(4)S3, with 2-way mutual redistribution between a RIPv2 domain and OSPF domain (picture attached)

 

Has anyone come across any issues in this code, whereby RIP strips the tag of OSPF routes redistributed into RIP? The closest I've come across is this https://community.cisco.com/t5/routing/redistribute-ospf-into-rip-with-tags/td-p/1185731

 

On R1 and R2, I have the following route-maps;

route-map RIPTOOSPF deny 10
match tag 1
!
route-map RIPTOOSPF permit 20
set tag 120
!
route-map OSPFTORIP deny 10
match tag 120
!
route-map OSPFTORIP permit 20
set tag 1

 

R1 & R2

router ospf 1
redistribute rip metric-type 1 subnets route-map RIPTOOSPF
!
router rip
version 2
redistribute ospf 1 metric 10 route-map OSPFTORIP
network 13.0.0.0

 

I can see the assigned tag of 120, against the RIP prefixes in the LSDB.

However, R1 is still choosing the path to R4 for all RIP routes. It's just ignoring (or not seeing) the tag of 110 against the OSPF information, and so continues to prefer the long way around.

 

I can only assume, that either the tag of 110 isn't being applied on the way in to RIP, or it's being stripped on the way back out of RIP.

 

Am I going mad? Or has my time on route tagging been badly spent?

Many thanks.

1 Accepted Solution

Accepted Solutions

mrjdh
Level 1
Level 1

Don't worry. I'll hold my hands up and say I was just being stupid. Tagging isn't the correct method for this. I forgot the golden rule - always ensure your native routes have a lower AD value than the protocol which sold the routes back to you. 

 

The global distance within the RIP domain needs to be lower than 110.

View solution in original post

12 Replies 12

balaji.bandi
Hall of Fame
Hall of Fame

Can you post all the device full configuration. 

 

 

 

BB

***** Rate All Helpful Responses *****

How to Ask The Cisco Community for Help

Configs below:

 

R1

hostname R1
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
!
!
!
!
!
!
no ip domain lookup
ip domain name lab.local
ip cef
no ipv6 cef
!
!
multilink bundle-name authenticated
!
!
interface FastEthernet0/0
no ip address
shutdown
duplex full
!
interface GigabitEthernet1/0
ip address 13.13.13.1 255.255.255.0
negotiation auto
!
interface GigabitEthernet2/0
ip address 14.14.14.1 255.255.255.0
ip ospf 1 area 0
negotiation auto
!
router ospf 1
redistribute rip metric-type 1 subnets route-map RIPTOOSPF
!
router rip
version 2
redistribute ospf 1 metric 10 route-map OSPFTORIP
network 13.0.0.0
no auto-summary
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
route-map RIPTOOSPF deny 10
match tag 1
!
route-map RIPTOOSPF permit 20
set tag 120
!
route-map OSPFTORIP deny 10
match tag 120
!
route-map OSPFTORIP permit 20
set tag 1
!
!
!
control-plane
!
!
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line vty 0 4
login
!
!
end

 

R2

hostname R2
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
!
!
!
!
!
!
no ip domain lookup
ip domain name lab.local
ip cef
no ipv6 cef
!
!
multilink bundle-name authenticated

!
interface FastEthernet0/0
no ip address
shutdown
duplex full
!
interface GigabitEthernet1/0
ip address 23.23.23.1 255.255.255.0
negotiation auto
!
interface GigabitEthernet2/0
ip address 24.24.24.1 255.255.255.0
ip ospf 1 area 0
negotiation auto
!
router ospf 1
redistribute rip metric-type 1 subnets route-map RIPTOOSPF
!
router rip
version 2
redistribute ospf 1 metric 10 route-map OSPFTORIP
network 23.0.0.0
no auto-summary
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
route-map RIPTOOSPF deny 10
match tag 1
!
route-map RIPTOOSPF permit 20
set tag 120
!
route-map OSPFTORIP deny 10
match tag 120
!
route-map OSPFTORIP permit 20
set tag 1
!
!
!
control-plane
!
!
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line vty 0 4
login
!
!
end

 

R3

hostname R3
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
!
!
!
!
!
!
no ip domain lookup
ip domain name lab.local
ip cef
no ipv6 cef
!
!
multilink bundle-name authenticated
!
!
!
interface Loopback1
ip address 10.0.0.1 255.255.255.0
!
interface Loopback2
ip address 10.0.1.1 255.255.255.0
!
interface Loopback3
ip address 10.0.2.1 255.255.255.0
!
interface Loopback4
ip address 10.0.3.1 255.255.255.0
!
interface FastEthernet0/0
no ip address
shutdown
duplex full
!
interface GigabitEthernet1/0
ip address 13.13.13.2 255.255.255.0
negotiation auto
!
interface GigabitEthernet2/0
ip address 23.23.23.2 255.255.255.0
negotiation auto
!
router rip
version 2
network 13.0.0.0
network 23.0.0.0
no auto-summary
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
!
!
control-plane
!
!
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line vty 0 4
login
!
!
end

 

R4

hostname R4
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
!
!
!
!
!
!
no ip domain lookup
ip domain name lab.local
ip cef
no ipv6 cef
!
!
multilink bundle-name authenticated
!
interface Loopback1
ip address 172.16.4.1 255.255.255.0
ip ospf network point-to-point
ip ospf 1 area 0
!
interface Loopback2
ip address 172.16.5.1 255.255.255.0
ip ospf network point-to-point
ip ospf 1 area 0
!
interface Loopback3
ip address 172.16.6.1 255.255.255.0
ip ospf network point-to-point
ip ospf 1 area 0
!
interface Loopback4
ip address 172.16.7.1 255.255.255.0
ip ospf network point-to-point
ip ospf 1 area 0
!
interface FastEthernet0/0
no ip address
shutdown
duplex full
!
interface GigabitEthernet1/0
ip address 14.14.14.2 255.255.255.0
ip ospf 1 area 0
negotiation auto
!
interface GigabitEthernet2/0
ip address 24.24.24.2 255.255.255.0
ip ospf 1 area 0
negotiation auto
!
router ospf 1
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
!
!
control-plane
!
!
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line vty 0 4
login
!
!
end

R1

hostname R1
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
!
!
!
!
!
!
no ip domain lookup
ip domain name lab.local
ip cef
no ipv6 cef
!
!
multilink bundle-name authenticated
!
!
interface FastEthernet0/0
no ip address
shutdown
duplex full
!
interface GigabitEthernet1/0
ip address 13.13.13.1 255.255.255.0
negotiation auto
!
interface GigabitEthernet2/0
ip address 14.14.14.1 255.255.255.0
ip ospf 1 area 0
negotiation auto
!
router ospf 1
redistribute rip metric-type 1 subnets route-map RIPTOOSPF
!
router rip
version 2
redistribute ospf 1 metric 10 route-map OSPFTORIP
network 13.0.0.0
no auto-summary
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
route-map RIPTOOSPF deny 10
match tag 1
!
route-map RIPTOOSPF permit 20
set tag 120
!
route-map OSPFTORIP deny 10
match tag 120
!
route-map OSPFTORIP permit 20
set tag 1
!
!
!
control-plane
!
!
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line vty 0 4
login
!
!
end

 

R2

hostname R2
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
!
!
!
!
!
!
no ip domain lookup
ip domain name lab.local
ip cef
no ipv6 cef
!
!
multilink bundle-name authenticated
!
interface FastEthernet0/0
no ip address
shutdown
duplex full
!
interface GigabitEthernet1/0
ip address 23.23.23.1 255.255.255.0
negotiation auto
!
interface GigabitEthernet2/0
ip address 24.24.24.1 255.255.255.0
ip ospf 1 area 0
negotiation auto
!
router ospf 1
redistribute rip metric-type 1 subnets route-map RIPTOOSPF
!
router rip
version 2
redistribute ospf 1 metric 10 route-map OSPFTORIP
network 23.0.0.0
no auto-summary
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
route-map RIPTOOSPF deny 10
match tag 1
!
route-map RIPTOOSPF permit 20
set tag 120
!
route-map OSPFTORIP deny 10
match tag 120
!
route-map OSPFTORIP permit 20
set tag 1
!
!
!
control-plane
!
!
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line vty 0 4
login
!
!
end

 

R3

hostname R3
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
!
!
!
!
!
!
no ip domain lookup
ip domain name lab.local
ip cef
no ipv6 cef
!
!
multilink bundle-name authenticated
!
!
interface Loopback1
ip address 10.0.0.1 255.255.255.0
!
interface Loopback2
ip address 10.0.1.1 255.255.255.0
!
interface Loopback3
ip address 10.0.2.1 255.255.255.0
!
interface Loopback4
ip address 10.0.3.1 255.255.255.0
!
interface FastEthernet0/0
no ip address
shutdown
duplex full
!
interface GigabitEthernet1/0
ip address 13.13.13.2 255.255.255.0
negotiation auto
!
interface GigabitEthernet2/0
ip address 23.23.23.2 255.255.255.0
negotiation auto
!
router rip
version 2
network 13.0.0.0
network 23.0.0.0
no auto-summary
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
!
!
control-plane
!
!
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line vty 0 4
login
!
!
end

 

R4

hostname R4
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
!
!
!
!
!
!
no ip domain lookup
ip domain name lab.local
ip cef
no ipv6 cef
!
!
multilink bundle-name authenticated
!
!
interface Loopback1
ip address 172.16.4.1 255.255.255.0
ip ospf network point-to-point
ip ospf 1 area 0
!
interface Loopback2
ip address 172.16.5.1 255.255.255.0
ip ospf network point-to-point
ip ospf 1 area 0
!
interface Loopback3
ip address 172.16.6.1 255.255.255.0
ip ospf network point-to-point
ip ospf 1 area 0
!
interface Loopback4
ip address 172.16.7.1 255.255.255.0
ip ospf network point-to-point
ip ospf 1 area 0
!
interface FastEthernet0/0
no ip address
shutdown
duplex full
!
interface GigabitEthernet1/0
ip address 14.14.14.2 255.255.255.0
ip ospf 1 area 0
negotiation auto
!
interface GigabitEthernet2/0
ip address 24.24.24.2 255.255.255.0
ip ospf 1 area 0
negotiation auto
!
router ospf 1
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
!
!
control-plane
!
!
line con 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line aux 0
exec-timeout 0 0
privilege level 15
logging synchronous
stopbits 1
line vty 0 4
login
!
!
end

Hello

What you are doing is basically preventing routing loop between rip/opsf areas because you are not only performing mutual redistribution but also in two redistribution points.

 

Also I am on the understanding  route tags in rip mean nothing its only down to hop count, administrative and metrics, Now if you want to manipulate path preference in rip advertise ospf in to rip at R2 with an higher metric then that of R1 or vice versa.


Please rate and mark as an accepted solution if you have found any of the information provided useful.
This then could assist others on these forums to find a valuable answer and broadens the community’s global network.

Kind Regards
Paul

Thanks Paul.

 

So when it comes to route filtering using route tagging, are you basically saying that RIP will not honour the route tags? I was under the impression from reading that RIPv2 supports the use of tags, as per RFC1723?

 

The Route Tag (RT) field is an attribute assigned to a route which
   must be preserved and readvertised with a route.  The intended use of
   the Route Tag is to provide a method of separating "internal" RIP
   routes (routes for networks within the RIP routing domain) from
   "external" RIP routes, which may have been imported from an EGP or
   another IGP.

Hello

As per my understanding in essence yes - I think its to do with some internal mismatch values of rip as to eigrp or ospf - as you have stated your tagged route from rip into ospf work and you see them in the lsdb but your ospf to rip tagging you don’t see in rip or do you,They should be there but mean nothing interns of route manipulation?

 


Please rate and mark as an accepted solution if you have found any of the information provided useful.
This then could assist others on these forums to find a valuable answer and broadens the community’s global network.

Kind Regards
Paul

ulrickfr2001
Level 1
Level 1

I think the issue is related to the Administrative distance. 

 

Both routers redistribute the rip routes into ospf. Then both routers avertise theses routes to R4 and the Link States are propagated to R1 and R2. So the first router between R1 and R2 which will receive the routes redistributed from RP into his ospf database will compare the AD of RIP (120) vs AD of OSPF external (110) and then choose OSPF routes over RIP routes.

Hello


@ulrickfr2001 wrote:

I think the issue is related to the Administrative distance. 

 

Both routers redistribute the rip routes into ospf. Then both routers avertise theses routes to R4 and the Link States are propagated to R1 and R2. So the first router between R1 and R2 which will receive the routes redistributed from RP into his ospf database will compare the AD of RIP (120) vs AD of OSPF external (90) and then choose OSPF routes over RIP routes.

i don’t think using a single or multiple redistribution points should matter.


Please rate and mark as an accepted solution if you have found any of the information provided useful.
This then could assist others on these forums to find a valuable answer and broadens the community’s global network.

Kind Regards
Paul

Ok - can you confirm for sure? The only other opinion I have at present is from someone who believes that O E2 routes have the same AD value as internal EIGRP...

Hello

Easiest way would to check a ospf redistributed route in rip 

 

sh ip route x.x.x.


Please rate and mark as an accepted solution if you have found any of the information provided useful.
This then could assist others on these forums to find a valuable answer and broadens the community’s global network.

Kind Regards
Paul

mrjdh
Level 1
Level 1

Don't worry. I'll hold my hands up and say I was just being stupid. Tagging isn't the correct method for this. I forgot the golden rule - always ensure your native routes have a lower AD value than the protocol which sold the routes back to you. 

 

The global distance within the RIP domain needs to be lower than 110.

Exactly, That is what I said...

Review Cisco Networking for a $25 gift card