cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2567
Views
40
Helpful
22
Replies

Using two ISP Internet on router to achieve load sharing and failover

isaiahchikuse
Level 1
Level 1

I have one connection on BGP and other on static


How can i go about it to achieve load balance and failover with BGP and Static connections
can you share how i can achieve this?
.

Thanks

22 Replies 22

if you want static route to be primary so you dont need any thing, 
static route AD is lower than eBGP AD and hence router always select static route.
if you want eBGP to be primary then you need PBR to set next-hop is eBGP and if the next-hop failed then the router will use static route as it default behave.

Joseph W. Doherty
Hall of Fame
Hall of Fame

Possibly as simple as setting your static route's cost to match BGP's AD.  However, it gets more complex if BGP has more specific routes than your static routes.

Regarding failover, if BGP fails, all traffic should use just your statics until BGP comes back.  If static path fails, much depends on you statics configuration and nature of failure.  Port down on your side will disable statics, but port up but upstream failure will cause statics to black hole traffic.  The latter can be dealt with by IP SLA Failover.

Thomas Schmitt
Level 1
Level 1

There are uncomfortable solutions for traffic / load sharing between 2 ISPs. 

Most simple solution in your case is a default route to static ISP, so you will use BGP for specific routes and static for others. In case you have also from BGP default route, you can load balance (but per destination, not packet). For known address blocks, you can advertise a summary route from static site

There are things about this situation that we do not know and which make this a pretty complicated question. In particular:
- if one connection is on static, then is there a single static route or are there multiple static routes? Is the static route a default static or is/are there static routes for particular networks/subnets?

- does the BGP advertise just a single default route ? Or advertise a set of more specific prefixes? Or advertise both a default route and a set of more specific prefixes?

- does the static route/routes specify just the outbound interface, just a next hop address, or both a next hop address and outbound interface?

- is there any mechanism in the config to verify reachability of the next hop for the static route?

HTH

Rick

Hi Richard,

We asked the ISP on BGP to just give us a default route and we are advertising a single prefix on this link

B* 0.0.0.0/0 [20/0] via 41.x.x.x,

The other ISP(static) we just configured the route with next hop address

ip route 0.0.0.0 0.0.0.0 192.168.5.1

to answer last question, IP SLA is not yet configured but ping and traceroute going to the internet are able to go through this link.

 

Regards,

 

Ah, then I believe the "simple" solution I suggested earlier might work, i.e. just set the static default route cost to 20, same as BGP's.  Then see if both default routes appear in route table.

Again, with BGP being a dynamic routing protocol, router should use it or not depending whether BGP neighbor is "good" or not.  For the static, also again, it would only drop, by default, if its egress port drops.  To handle fault situations other than that, you'll need an IP SLA, possibly tied to next hop IP.  Reference I provided earlier should help explain how to configure.

@Joseph W. Doherty  I never lab it BUT I dont think it work, the bgp will not add prefix to rib instead it will mark it as rib failure in bgp table.

Hmm, @MHM Cisco World interesting possible issue.  Unfortunately, I don't have the equipment to lab it.  @Richard Burts, your thoughts?

As I was reading the thread I thought that your suggestion of setting AD of static to equal that of BGP was a good solution. But the suggestion from MHM about rib failure is vey interesting. I do not have the ability to test it, but I suspect that he may very well be right.

HTH

Rick

I did some searching and found this explanation about rib failure "Route with better administrative distance already present in IGP. For example, if a static route already exists in IP Routing table." Here is the link if you want to check it out:

https://www.cisco.com/c/en/us/support/docs/ip/border-gateway-protocol-bgp/5816-bgpfaq-5816.html?dtid=osscdc000283#anc25

So if rib failure considers AD then I believe that the suggestion of setting static AD equal to BGP probably will work.

HTH

Rick

Thanks Rick!

I do see in that reference it refers to the IGP having a better AD, not equal AD, so as you note it might work after all.

Perhaps the OP might try it.

prefix mark as RIB-failure in bgp table  as I guess before.
jjjjjjjllllllkkkkk.png

Interesting.

What do you do this on/with?

Could you post configs?

Indeed interesting. Not what I expected. But pending config details it does appear that actual experience does trump possible ambiguity in documentation.

HTH

Rick