Cisco Support Community
Showing results for 
Search instead for 
Did you mean: 

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

New Member

BGP Configuration with Dual ISP


Just wanted to ask what could be the ideal setup with two upstreams?

I'm planning to do like:

ISP_1    ISP_2

   |            |

   | eBGP  |eBGP

   |            |

RTR1    RTR2

   |           |

   \iBGP  /iBGP

    \        /



I'm quite newbie in setting iBGP and eBGP. Really appreciate if anybody could help me or anyone could post a sample configuration to make this work? My objective is also to load-balance the traffic between two ISPs.



Re: BGP Configuration with Dual ISP


I think you are on a good path.

You'll want an underlying IGP between your iBGP peers.  OSPF for a more mature engineering support staff or EIGRP others.  After this create a full mesh with your iBGP sessions.  Generally folks use loopback addresses to peer with iBGP because it creates a fault tolerant environment.  The IGP you implemented will facilitate the peering over loopbacks.

Next establish your eBGP sessions with your service providers.  These are generally developed over the physical interfaces facing the service provider.

Use 'AS-Path prepend' in an attempt in influence how traffic comes into your network from the internet.  Use 'local-preference' to influence how traffic exits your network.  For a dynamic method of load sharing in regard to how traffic exits your network look into OER.


New Member

Re: BGP Configuration with Dual ISP

Hi Chris,

Thank you for your kind reply.

So, if I have something like: and

Both networks will be advertised by ISP_1 and ISP_2? If I understand it right. Both networks will also be defined to both RTR1 and RTR2 ? and then I will just create prefixes say for example by /24 ? and so the routing decisions will be made accordingly at both RTR1 and RTR2 and not in RTR3? Sorry for these questions, I would like really to understand the correct way of doing this and pretty much administer it in the right way.

Thanks again.


Re: BGP Configuration with Dual ISP


Yes both networks will need to be announced to both your service providers.

In my opinion you should announce the prefixes to your service providers as they appear in ARIN. 

De-aggregateing the internet table is something of a party foul as folks like to keep it as small as possible; it's already quite huge.  Given the size of the public prefixes it question it makes good sense that they would exist as /24 networks in the server farm.  In this case allow the /24's to be propagated by the IGP.  On RTR 1 & 2 install null routes for the proper internet prefixes.

ip route null 0
ip route null 0

At this point the larger prefixes will be in the routing table; a prerequisite to be in the BGP table.  Then announce them to your service provider with the following network statements.

router BGP XXXXX
network mask
network mask

Let's say you have a server network with a subnet of  The prefix advertised via BGP to the internet will attract internet traffic destined to it.  Once RTR 1 or 2 receives the packet these routers will have a more specific route to the /24 network and send it on to your server farm.  Routers match on the longest mask first; in this case avoiding the null or 'tie down' route used to advertise your public space to the internet. 


New Member

Re: BGP Configuration with Dual ISP

Hi Collin,

Thank you again for your kind reply. This helped me better understand how BGP works.