Showing results for 
Search instead for 
Did you mean: 

OSPF Route Remains in Table

Simon Young

I have an issue where I am advertising two default routes, one from a primary and another from the backup site

One is OSPF(backup) and the other is iBGP(primary). There are two eBGP routers connected to ISP, with a switch behind them

The switch is iBGP peering with the routers and OSPF peering with a FW

I would like the iBGP route to be used, unless the BGP advertised default route drops out of the routing table

The OSPF default should then be used until the BGP route is restored

under BGP I have used the following command

distance 100 x.x.x.x Default

ip access-list standard Default

This gives the iBGP route a AD of 100, lower than OSPF.

This works but the problem I have is the only way I can flip back to the iBGP default route is by removing the default route from OSPF or clearing the ip ospf process. This is fine in a test environment but not in the real world.

Ideally the default route comes back in from the BGP side and the OSPF is replaced.


1 Reply 1


Hi Simon,

I would recommend redistributing the BGP learned default route into OSPF, and influencing the metrics within OSPF to favour the route learned via the ISP. This can be done at the point of redistribution through a number of methods.


It's much cleaner to influence routing within the same IGP rather than trying to play around with the admin distances.


Hope that helps,



HTH Paul ****Please rate useful posts****
Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Recognize Your Peers