cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2565
Views
0
Helpful
7
Replies

OSPF inject default route but restrict interfaces

jeremy.t
Level 1
Level 1

Hi, can anyone tell me if it is possible to inject the default route into OSPF but only allow it out certain interfaces. For example I want to send it out a couple of tunnels but nowhere else. I assume if it is possible it would be by using a route-map with the default-information originate command but I can't see how.

Thanks

7 Replies 7

cadet alain
VIP Alumni
VIP Alumni

Hi,

the default-information originate route-map command is for conditional injection of the default-route not to filter the advertisement from some interfaces.

Can you post your topology to see if it's possible to achieve what you want to do.

Regards.

Alain.

Don't forget to rate helpful posts.

Hi Alain, thanks for your quick reply.

We have two main data centres in the UK that all other UK locations connect to, OSPF is used throughout but the default route is static everywhere. We have a location in Dubai that is connected to the UK via internet VPN's, they have two internet circuits on two routers. Each router has a VPN to both UK data centres with GRE tunnels and OSPF.

I want to be able to pass the default route to Dubai from both UK data centres for full resilience.

Hope that makes sense. Any ideas?

Hi,

I don't see any way to restrict advertisement of default-route by OSPF per interface but if you want some sites not inserting it into routing table then you could do a distribute-list inbound on these routers  so the route will still be in the OSPF database but not installed into RIB.

Regards.

Alain.

Don't forget to rate helpful posts.

Well as Alain mentioned with ospf you can't filter a route in the outbound direction

However there are to way two ways you can do it to your solution

Long one

Do inbound filtering where you do not want to receive the default route over the ospf

Simple one

As long as the other locations uses static default route and static route by default has lower administrative distance then even if the uk sites receive the default route over ospf it will not install it in the routing table as long as there is default static route with lower AD and it will be the preferred one

If Dubai sites has no default static routes, or at least not default static with lower distance than ospf the. It will use it over the gre tunnel

In other words just generate the default route and that's it assuming uk sites uses static default route locally

Hope this help

Forgot to mention third method

Which by making the gre tunnel to dubai locations in another area (assuming uk in area 0 ) and make this area as totally stubby area this way ospf will generate default route only to that location

If you make it as stub default route will be sent a long with the inter area route to those areas

See the bellow link if you want to go with this type of design

http://www.cisco.com/en/US/tech/tk365/technologies_tech_note09186a0080094a74.shtml

Hope this help

If helpful rate

Thanks for your replies.

Funny I was thinking over night why not just advertise the default route via OSPF if everywhere else does have static default routes. On Monday I'll check to make sure everywhere else does have them and also look into why they do. It would make far more sense to me for it to be dynamic.

Marwan ALshawi
VIP Alumni
VIP Alumni

Yes this is simplest way

Or using stub or totally stub area the other simple way

Hope this help

Sent from Cisco Technical Support iPhone App

Review Cisco Networking for a $25 gift card