10-15-2007 06:51 AM - edited 03-03-2019 07:10 PM
If I'm using OSPF as my IGP routing between the internal networks and I have 2 different BGP default routes. How do i setup OSPF to be able to use either one of the routes or both?
10-15-2007 07:17 AM
The way I see the solution, redistribute BGP in to OSPF with metric-type E1. This way, it would calculate the metric to reach destination as aggregate of metric used for redistribution + metric before redistribution.
however, you may use route-maps to prevent BGP from flooding the routing table & redistribute only default-routes.
10-15-2007 10:01 AM
What if I use this, will it cause a loop?
ISP-R1: 10.0.0.1
ISP-R2: 20.0.0.1
Customer-R3: 10.0.0.2 30.0.0.1/24
Customer-R4: 20.0.0.2 30.0.0.2/24
Customer-R3:
router bgp 100
neighbor 10.0.0.1 remote-as 200
neighbor 20.0.0.2 remote-as 100
neighbor 20.0.0.2 next-hop-self
bgp redistribute-internal
router ospf 10
redistribute bgp 100 route-map mydef
ip prefix-list def-route seq 5 permit 0.0.0.0/0
route-map mydef permit 10
match ip address prefix-list def-route
Customer-R4:
router bgp 100
neighbor 20.0.0.1 remote-as 200
neighbor 10.0.0.2 remote-as 100
neighbor 10.0.0.2 next-hop-self
bgp redistribute-internal
router ospf 10
redistribute bgp 100 route-map mydef
ip prefix-list def-route seq 5 permit 0.0.0.0/0
route-map mydef permit 10
match ip address prefix-list def-route
If I have a 3rd router running ospf, would this create 2 default route entries? Can I get a loop somehow?
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide