BGP anouncing with two peers.
Damjan
gdamjan at mail.net.mk
Mon Dec 24 13:52:22 CET 2001
>
> Please, if you get the answers, could you send me a copy ?
Hello, I've succeded in making Bird BGP work.
I'm now using it to anounce my ISP's ip address pool to the
world, through two peers. Also I prepend the routes I anounce so
part of my IP's are routed through one peer, and the other part
through the other peer. Curently I'm only anouncing (exporting)
BGP routes, I don't import nothing.
Next thing I'll do is try to manipulate my router's two routing
tables when a BGP session is broken, so that I can get automatic
switchover of the uplink too. This will require a different Bird
configuation and I'll do it once I get more familiar with Bird's
scripting language.
This is the configuration I used, atached. If you have any
questions feel free to ask me.
--
Damjan Georgievski | Дамјан Георгиевски
Skopje, Macedonia | Скопје, Македонија
-------------- next part --------------
router id IP.ADDRESS.BGP.ROUTER;
log "/var/log/bird.log" all;
debug protocols all;
debug commands 2;
protocol device {
# This is neceseary for Bird to work at all.
# BTW it's not in the documentation.
scan time 60;
}
# I have a 1.1.64.0/19 netmask, divided in two subnets
# so that I can route them separately.
protocol static pool1{
route 1.1.64.0/20 via IP.ADDRESS.BGP.ROUTER;
}
protocol static pool2{
route 1.1.80.0/20 via IP.ADDRESS.BGP.ROUTER;
}
protocol bgp {
local as MY_AS;
source address IP.ADDRESS.BGP.ROUTER;
multihop 20 via IP.ADDRESS.BGP.ROUTER;
neighbor PEER1.IP.ADDRESS as PEER1_AS;
import none;
export filter {
if net ~ [ 1.1.64.0/20+] then {
bgp_path.prepend(MY_AS);
bgp_path.prepend(MY_AS);
bgp_path.prepend(MY_AS);
accept;
}
if net ~ [ 1.1.80.0/20+] then {
accept;
}
reject;
};
}
protocol bgp {
local as MY_AS;
source address IP.ADDRESS.BGP.ROUTER;
multihop 20 via IP.ADDRESS.BGP.ROUTER;
neighbor PEER2.IP.ADDRESS as PEER2_AS;
import none;
export filter {
if net ~ [ 1.1.64.0/20+] then {
accept;
}
if net ~ [ 1.1.80.0/20+] then {
bgp_path.prepend(MY_AS);
bgp_path.prepend(MY_AS);
bgp_path.prepend(MY_AS);
accept;
}
reject;
};
}
More information about the Bird-users
mailing list