On Thu, Mar 23, 2006 at 02:44:46PM +0100, Marcel Prisi wrote:
> Claudio Jeker a icrit :
> 
> >This is not possible in OpenBGPD. I'm not even sure why we should add
> >something like that. Could you please tell me why you need to change
> >localpref depending on the path length?
> >The BGP decision process checks this:
> >1) nexthop state (reachable or not)
> >2) localpref
> >3) as path lenght
> >4) origin
> >5) MED
> >6) EBGP vs. IBGP
> >7) OpenBGPD special weight
> >8) nexthop costs (not implemented in OpenBGPD as there is no cost stored
> >in the routing table)
> >9) route age if route-age evaluation is enabled
> >10) BGP Id
> >11) IP
> >
> >As you can see the AS Path length is compared right after the localpref so
> >twisting the localpref depending on the AS Path lenght does not change
> >that much.
> > 
> >
> The trouble we have is that we have two upstreams with different bandwidth.
> 
> The one with the smallest bandwidth has better routes, so close to all 
> traffic goes through it, which is not optimal.
> 
> We already kind of solved inbound traffic using prepending & communities.
> 
> We modified "local pref" for the outgoing traffic, but now all traffic 
> goes through the other upstream, and nothing more through the smallest 
> one, which is still not optimal.
> 
> What I wanted is to force some kind of discrimination so that smaller 
> AS-paths go through one, and bigger through the other, so that I have an 
> arbitrary way to balance between the two upstreams.
> 

Normaly you prepend some AS to the smaller link to make the pathes comming
from that link more or less equal length with the other one.
You may additionally classify the prefixes by communities but that only
works if your uplink provider is setting them with some useful value.
There are some other tricks like tagging the uplinks of your uplink
provider. But your right we need AS path regex support...

> I may try using "prefixlen" insted ... would something like
> 
> match prefixlen > 16 set localpref +10
> 

This will not make you happy. Prefixlen is not a good discriminator you
may select the worst path and end up with non optimal routing.

One important thing about traffic engineering is to know your traffic.

-- 
:wq Claudio

Reply via email to