cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
993
Views
0
Helpful
2
Replies
Beginner

Remove BGP Default Route When Using IP SLA

Hello, I have an Internet router. The external interface is running BGP towards the ISP. We are not doing any BGP peering, etc.. Basic BGP neighbor with ISP. The internal interface is running OSPF.

 

I have an IP SLA monitoring an upstream address 8.8.8.8. 

 

I have the following static route:

ip route 0.0.0.0 0.0.0.0 1.1.1.1 track 1

 

This is my OSPF config:

redistribute static subnets
default-information originate

 

Everything works fine re the default route propagating through my OSPF domain when 8.8.8.8 is pingable and the track is up. However, when 8.8.8.8 is not reachable (simulating an upstream ISP outage) and the track goes down, the static default route is removed, but then BGP's default route kicks in. Traffic is still routed towards the Internet router but the ISP is down. We have another ISP in another location that is distributing its default route which ideally that is the path it should take when the ISP is down.

 

1) The ultimate question is, can I remove BGP's default route? I do not want any default route if my IP SLA is down.

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Remove BGP Default Route When Using IP SLA

Hi,


@matthubach wrote:

 

1) The ultimate question is, can I remove BGP's default route? I do not want any default route if my IP SLA is down.


Yes, you can. Since you are adding a static default route pointing towards ISP1, you can take out BGP default route and still send your traffic using the static route configured.

 

First, check whether you are receiving default route from your ISP1 by running "sh ip bgp x.x.x.x received-routes". If you do and if you are receiving default route, you can filter default route from received routes as follows:

 

config t

ip prefix-list FILTER_DEFAULT_ROUTE deny 0.0.0.0/0

ip prefix-list FILTER_DEFAULT_ROUTE permit 0.0.0.0/1 le 32  ! If you are receiving other routes and wants to keep them. 

!

router bgp YY

 neighbor x.x.x.x prefix-list FILTER_DEFAULT_ROUTE in  ! Add this line to your existing configuration.

 

 

HTH,

Meheretab

2 REPLIES 2

Re: Remove BGP Default Route When Using IP SLA

Hi,


@matthubach wrote:

 

1) The ultimate question is, can I remove BGP's default route? I do not want any default route if my IP SLA is down.


Yes, you can. Since you are adding a static default route pointing towards ISP1, you can take out BGP default route and still send your traffic using the static route configured.

 

First, check whether you are receiving default route from your ISP1 by running "sh ip bgp x.x.x.x received-routes". If you do and if you are receiving default route, you can filter default route from received routes as follows:

 

config t

ip prefix-list FILTER_DEFAULT_ROUTE deny 0.0.0.0/0

ip prefix-list FILTER_DEFAULT_ROUTE permit 0.0.0.0/1 le 32  ! If you are receiving other routes and wants to keep them. 

!

router bgp YY

 neighbor x.x.x.x prefix-list FILTER_DEFAULT_ROUTE in  ! Add this line to your existing configuration.

 

 

HTH,

Meheretab

Beginner

Re: Remove BGP Default Route When Using IP SLA

Thanks Meheretab, I will give this a shot soon.

CreatePlease to create content
Content for Community-Ad
July's Community Spotlight Awards