Activate local_pref calculation based on communities
This commit is contained in:
parent
8c8d48733f
commit
3d0bf0d9ed
|
@ -43,6 +43,11 @@ int dn42_crypto;
|
|||
dn42_crypto = update_crypto(link_crypto) - 30;
|
||||
# replace 4 with your calculated bandwidth value
|
||||
if dn42_bandwidth > 4 then dn42_bandwidth = 4;
|
||||
|
||||
bgp_local_pref = 10000+100*dn42_bandwidth + 50*(10-dn42_latency)-200*bgp_path.len+100*dn42_crypto; #(as suggested by tombii)
|
||||
bgp_local_pref = 1000*dn42_bandwidth - 10*dn42_latency; if dn42_crypto < 2 then bgp_local_pref = 0; #(as suggested by Jplitza)
|
||||
bgp_local_pref = 10000+100*dn42_bandwidth + 50*(10-dn42_latency)-400*(bgp_path.len-1)+100*dn42_crypto; #(as suggested by Mic92 - prefer direct tunnel)
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue