mrtdump protocols all;
mrtdump "/tmp/bird_bgp";

log syslog { debug, trace, info, remote, warning, error, auth, fatal, bug };
log stderr all;
log "/var/log/bird.log" all;
debug protocols all;

watchdog warning 5 s;
watchdog timeout 30 s;

router id 192.168.0.16;

protocol kernel {
    learn;
    scan time 20;
    export all;
}

protocol device {
    scan time 10;
}

protocol direct {
    interface "*";
}

protocol static {
    route 192.168.16.0/24 unreachable;
}

filter ibgp_out {
    if source = RTS_STATIC then {
        bgp_large_community.add((65000,4294967295,100));
        bgp_large_community.add((65000,4294967295,200));
        bgp_large_community.add((65000,4294967295,300));
        accept;
    }
    reject;
}

protocol bgp {
    hold time 90;
    startup hold time 10;
    connect retry time 10;
    keepalive time 30;
    local as 65000;
    neighbor 192.168.0.10 as 65000;
    add paths on;
    enable route refresh on;
    graceful restart on;
    enable as4 on;
    export filter ibgp_out;
}
