cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1023
Views
9
Helpful
7
Replies

load balancing over two links using BGP

nkariyawasam
Level 1
Level 1

I have two locations ( head office and branch), connected via two parallel links.

I have given AS numbers as follows;

Head office: AS64600, Branch : As64601.

Link #1 is a layer 2 link between two locations.

Link #2 is Layer 3 link going through another service proivider (AS65000).

I am trying to load share over these two links using BGP multipath feature (command "maximum-paths 2" command ).

First there was an issue with differant AS_PATH parameter over two links. We were able to solve this using router-map which prepends additional AS number to link #1 ( Thanks to the forum).

After equalizing all the parameters which affects the BGP path selection, still router failing to install two paths in to routing table.

Routing info looks like follows;

( 172.20.7.0 is a H/O network advertized to branch over two links using BGP).

Branch(1700)#sh ip bgp 172.20.7.0

BGP routing table entry for 172.20.7.0/24, version 230

Paths: (2 available, best #2, table Default-IP-Routing-Table)

Multipath: eBGP

Flag: 0x820

Advertised to update-groups:

1

64600 64600

172.30.29.2 from 172.30.29.2 (172.20.100.1)

Origin IGP, metric 500, localpref 100, valid, external

65000 64600

172.25.39.181 from 172.25.39.181 (172.25.39.13)

Origin IGP, metric 500, localpref 100, valid, external, best

Extended Community: RT:65000:741

The routing table looks like this;

Branch(1700)#sh ip route 172.20.7.0

Routing entry for 172.20.7.0/24

Known via "bgp 64601", distance 20, metric 500

Tag 65000, type external

Last update from 172.25.39.181 00:02:36 ago

Routing Descriptor Blocks:

* 172.25.39.181, from 172.25.39.181, 00:02:36 ago

Route metric is 500, traffic share count is 1

AS Hops 2

Route tag 65000

Any thoughts why the router is failing to install multiple paths ?

7 Replies 7

mheusinger
Level 10
Level 10

Hello,

the requirement not fulfilled is mentioned in "Configuring BGP":

11. If the following conditions are all true, insert the route for this path into the IP routing table:

–Both the best route and this route are external.

! this is the case

–Both the best route and this route are from the same neighboring autonomous system.

! this is unfortunately not the case

–maximum-paths is enabled.

! This is the case

Or from another source "BGP Best Path Selection Algorithm":

http://www.cisco.com/en/US/tech/tk365/technologies_tech_note09186a0080094431.shtml#bgpmpath

In order to be candidates for multipath, paths to the same destination need to have these characteristics equal to the best-path characteristics:

Weight

Local preference

AS-PATH length

Origin

MED

One of these:

Neighboring AS or sub-AS (before the addition of the eiBGP Multipath feature)

AS-PATH (after the addition of the eiBGP Multipath feature)

So as it looks it will not be working unless you modify the path on your 64600 site. You could set the path to be 65000 64600 with a route-map and local-as feature.

Hope this helps! Please rate all posts.

Regards, Martin

Hi Martin,

Ref to

Is this requirement valid even in simple BGP network.? I thought its required in MPLS BGP network..

Rgds,

Gaurav

Hi Gaurav,

that requirement is generically for BGP.

HTH

Andrea

Hi Martin,

I have made equal all the paramaters for both paths ( looking from the branch side).

Please refer to the "show ip bgp 172.20.7.0" output shows following;

64600 64600

172.30.29.2 from 172.30.29.2 (172.20.100.1)

Origin IGP, metric 500, localpref 100, valid, external

65000 64600

172.25.39.181 from 172.25.39.181 (172.25.39.13)

Origin IGP, metric 500, localpref 100, valid, external, best

Extended Community: RT:65000:741

So both paths have same local pref (100), AS path length (2), origin (IGP), MED ( not applicable).

The next thing AFTER MED is not clear to mer; I bileve what matters is AS-PATH after addition of eBGP mutilpath feature in our case. But what is meant by AS-PATH ? Does it means that we have to equate AS-PATH patemeter for both paths ?

Hi,

it should look like:

===>65000 64600 <====

172.30.29.2 from 172.30.29.2 (172.20.100.1)

Origin IGP, metric 500, localpref 100, valid, external

65000 64600

172.25.39.181 from 172.25.39.181 (172.25.39.13)

Origin IGP, metric 500, localpref 100, valid, external, best

Or 64600 64600 for both pathes.

You can modify AS-PATH when sending through the "local-as" feature. A BGP speaker will then send a configurable AS number in the path instead of the one after "router bgp".

This means to mess around with normal AS-PATH processing and you should be careful to avoid loops.

Have a look at:

"Configuring the BGP Local-AS Feature"

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

Following this a sample config could look like this (and should be ok in your environment without loops):

Router main site:

router bgp 64600

neighbor 192.168.1.1 remote-as 64601

neighbor 192.168.1.1 local-as 65000

neighbor 192.168.1.1 route-map set-as out

!

route-map set-as permit 100

set as-path prepend 64600

peering Router:

router bgp 64601

neighbor 192.168.1.2 remote-as 65000 !!

This should allow to adjust the path to show 65000 in first position for both pathes and therefore fulfill the multi-path requirements.

Off course you need to adjust IP addresses and further BGP commands to your environment.

Hope this helps! Please rate all posts.

Regards, Martin

Hi Martin,

Thank you very much for your very descriptive answer and that resolved our issue.

One little thing; When we prepend 64600 using route-map the two paths were shown as follows;

Advertised to update-groups:

1

65000 64600 64600

172.30.29.2 from 172.30.29.2 (172.20.100.1)

Origin IGP, metric 0, localpref 100, valid, external

65000 64600

172.25.39.181 from 172.25.39.181 (172.25.39.13)

Origin IGP, localpref 100, valid, external, best

Extended Community: RT:65000:741

So, the HO router already prepends its AS number ; therefore we remove the route map.

It worked !

One more question;

This case link #2 is a L2 link.

But if the link #2 is layer 3 and goes through another SP ( obviuosly having differant AS number) and we want to load balance.

then there is no way to make two AS-PATH parameter equal ???

Hi,

according to the descriptions above you can not load balance for one prefix when the two pathes are different. In fact your case looked to the peering router like "originated in 64600 and going through another SP: 64600". The point is here that the value of the ASes in the path does not matter (except own AS).

So the usual trick in the internet is to split the IP address space and do a sort of load sharing prefering one prefix through one ISP and the other prefix through the other ISP.

Regards, Martin

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card