BIRD: BGP route-reflector

In this example, a server running BIRD will function as a route-reflector for two MX-routers:

The BIRD configuration is quite easy to understand and use. There is only one thing about BIRD and BGP that requires additional clarification in advance.

By default, BIRD uses the 'master' table. In this scenario, I created a separate table called 'inet0'. This will be the table that BIRD is going to use to store BGP routes. What BIRD will not do is resolve the next-hop from that same table. By configuring 'igp table master', BIRD will resolve the next-hop by consulting the master table.

Also, since a BIRD RR might be better off placed outside of the forwarding path, the BIRD RR is a non-forwarding RR. I hope the other comments are elaborative enough;

[root@bird ~]# more /etc/bird.bgp
# creating a separate table for BIRD to store BGP routes
table inet0;

# the following is a template. The template needs to be applied to individual neighbors.

template bgp RR {
        debug all;                                  # debug BGP
        description "BIRD RR";
        local as 1;                                 # the AS used by the local BGP speaker
        multihop;                                   # was not default in 1.3.11
        rr client;                                  # make defined neighbors rr clients
        igp table master;                           # necessary to resolve the next-hop
        table inet0;                                # make BGP use this table
        import all;                                 # just accept everything
        export all;                                 # and advertise it to all the neigbors
        connect retry time 10;                      # reconnect try after 10s
        hold time 30;                               # hold time send in BGP messages
        source address;                # Source BGP from this IP address

# neighbors can be added in the following file:
include "bird.bgp.clients";

The route-reflector clients:

[root@bird ~]# more /etc/bird.bgp.clients
#  from ‘RR’ refers to the template stored in bird.bgp
protocol bgp Tiberius from RR { neighbor as 1; };
protocol bgp Commodus from RR { neighbor as 1; };

After activating this configuration, you can issue the following command to examine the BGP table ‘inet0’;

[root@bird ~]# birdc show route all table inet0
BIRD 1.3.11 ready.    via on eth1 [Tiberius 14:03 from] * (100/?) [i]
        Type: BGP unicast univ
        BGP.origin: IGP
        BGP.local_pref: 100

To verify that the route, received from Tiberius, was forwarded by BIRD:

play@MX480-TEST-RE0:Commodus> show route receive-protocol bgp detail

inet.0: 34 destinations, 35 routes (30 active, 0 holddown, 4 hidden)
* (1 entry, 1 announced)
     Localpref: 100
     AS path: I (Originator)
     Cluster list:
     Originator ID:

A nice thing about BIRD is that it allows you to store the configuration in different files. In this example, I made use of the following files:

The ‘bird.conf’ file references bird.ospf and bird.bgp. The route-reflector clients are put into a separate file which is referenced by bird.bgp.

First, the content of bird.conf:

router id;

debug protocols all;

protocol device {
        scan time 10;

include "bird.ospf";

include "bird.bgp";

The OSPF configuration (same as in a previous post):

[root@bird ~]# more /etc/bird.ospf
protocol ospf {
        debug all;
        area 0 {
                interface "eth1" {
                        passwords {
                                password "LaLa" {
                                        id 1;
                                        generate from "01-01-2000 00:00:00";
                                        accept from "01-01-2000 00:00:00";
                        cost 5;
                        type pointopoint;
                        hello 5; retransmit 2; wait 10; dead 20;
                        authentication cryptographic;
                interface "lo" {
                        cost 1000;