cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
375
Views
4
Helpful
4
Replies

BGP Conditional Advertisement

mindgenie
Level 1
Level 1

We are running BGP with two Service Providers, The requirement is to use SP1 as primary and SP2 as backup. Want to achieve this by using conditional advertisement.

Current config is:

router bgp xxxxx

no synchronization

bgp log-neighbor-changes

network xxx.xx.x44.0

network xxx.xx.x48.0

network xxx.xx.x49.0

network xxx.xx.x50.0

network xxx.xx.x51.0

neighbor yy.yyy.yyy.17 remote-as yyyyy

neighbor yy.yyy.yyy.17 route-map localonly out

neighbor zzz.zzz.zzz.189 remote-as zzzzz

neighbor zzz.zzz.zzz.189 route-map localonly out

!

ip route 0.0.0.0 0.0.0.0 yy.yyy.yyy.17

ip route 0.0.0.0 0.0.0.0 zzz.zzz.zzz.189

ip as-path access-list 10 permit ^$

!

route-map localonly permit 10

match as-path 10

x is for my network

y is for SP1

z is for SP2

4 Replies 4

Hello,

if you want to use conditional advertising, you could do the following:

Add a tag to the default route pointing to your primary ISP:

ip route 0.0.0.0 0.0.0.0 yy.yyy.yyy.17 tag 10

Add the following to your route map:

route-map localonly permit 10

match tag 10

set weight 200

This way you default route pointing to SP1 would always have a higher wight and therefor be preferred.

The same could be achieved by spwcifying the weight in your neighbor statement:

neighbor yy.yyy.yyy.17 weight 200

Or you could use local preference:

neighbor yy.yyy.yyy.17 local-preference 200

HTH,

GP

Your answer serves the purpose, but there are some upcoming requirements in which I have to advertise certain classes on one network and other class on second network. And in case of any link failure remaining link will carry all the traffic.

forsudhaji
Level 1
Level 1

Your requirement is to use SP1 as primary and SP2 as backup - OK..What can be done is -

1. For the incoming traffic from Internet -

a. Advertise all your IP subnets on both of the SP links.. For the Sec SP link add a route map to the outgoing advertisement and set AS PAth Prepend..

2. For the outgoing traffic from ur network ..

a. Set local preference for the incoming traffic..

Hope the above solution will work..

Pls let me know for further queries..

Harold Ritter
Cisco Employee
Cisco Employee

Here's a good paper on the BGP conditional advertisement feature.

http://www.cisco.com/en/US/partner/tech/tk365/tk80/technologies_configuration_example09186a0080094309.shtml

Let me know if it helps,

Harold Ritter
Sr Technical Leader
CCIE 4168 (R&S, SP)
harold@cisco.com
México móvil: +52 1 55 8312 4915
Cisco México
Paseo de la Reforma 222
Piso 19
Cuauhtémoc, Juárez
Ciudad de México, 06600
México