BIRD router/route server functions

Rae Ho (ITSC) raeho at cuhk.edu.hk
Tue Jun 5 11:29:08 CEST 2018


Dear Quan Zhou, Thanks. Rae

Router1
ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN qlen 1
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: ens160: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
    link/ether 00:0c:29:37:43:ca brd ff:ff:ff:ff:ff:ff
    inet 192.168.199.12/24 brd 192.168.199.255 scope global ens160
       valid_lft forever preferred_lft forever
    inet6 fe80::20c:29ff:fe37:43ca/64 scope link
       valid_lft forever preferred_lft forever
[root at gobgp-raeho ~]# ip route
default via 192.168.199.254 dev ens160  proto static  metric 100
10.99.13.0/24 via 192.168.199.12 dev ens160  proto bird
192.70.0.0/24 via 192.168.199.12 dev ens160  proto bird
192.168.199.0/24 dev ens160  proto kernel  scope link  src 192.168.199.12  metric 100
[root at gobgp-raeho ~]# birdc show interfaces
BIRD 1.4.5 ready.
lo up (index=1)
        MultiAccess AdminUp LinkUp Loopback Ignored MTU=65536
        127.0.0.1/8 (Primary, scope host)
ens160 up (index=2)
        MultiAccess Broadcast Multicast AdminUp LinkUp MTU=1500
        192.168.199.12/24 (Primary, scope site)


Router 2
ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN qlen 1
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: ens160: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000
    link/ether 00:0c:29:37:43:ca brd ff:ff:ff:ff:ff:ff
    inet 192.168.199.13/24 brd 192.168.199.255 scope global ens160
       valid_lft forever preferred_lft forever
    inet6 fe80::20c:29ff:fe37:43ca/64 scope link tentative dadfailed
       valid_lft forever preferred_lft forever
[root at gobgp2-raeho ~]# ip route
default via 192.168.199.254 dev ens160  proto static  metric 100
10.99.12.0/24 via 192.168.199.13 dev ens160  proto bird
192.70.3.0/24 via 192.168.199.13 dev ens160  proto bird
192.168.199.0/24 dev ens160  proto kernel  scope link  src 192.168.199.13  metric 100
[root at gobgp2-raeho ~]# birdc show interfaces
BIRD 1.4.5 ready.
lo up (index=1)
        MultiAccess AdminUp LinkUp Loopback Ignored MTU=65536
        127.0.0.1/8 (Primary, scope host)
ens160 up (index=2)
        MultiAccess Broadcast Multicast AdminUp LinkUp MTU=1500
        192.168.199.13/24 (Primary, scope site)

From: Bird-users <bird-users-bounces at network.cz> On Behalf Of Quan Zhou
Sent: Tuesday, June 5, 2018 5:08 PM
Cc: bird-users at network.cz
Subject: Re: BIRD router/route server functions

Please try following:

ip addr
ip route
birdc show interfaces

On Tue, Jun 5, 2018 at 4:04 PM Rae Ho (ITSC) <raeho at cuhk.edu.hk<mailto:raeho at cuhk.edu.hk>> wrote:
are you able to ping each other from either host? <-- Yes, Can Ping

May I know is there any network/IGP setup first?
if they are directly connected or correctly routed then no prior work needs to be done.

Rae

From: Bird-users <bird-users-bounces at network.cz<mailto:bird-users-bounces at network.cz>> On Behalf Of Quan Zhou
Sent: Tuesday, June 5, 2018 3:51 PM

Cc: bird-users at network.cz<mailto:bird-users at network.cz>
Subject: Re: BIRD router/route server functions

>> Last error:       Socket: No route to host

looks like the problem is not with the bird. Although it looks like both hosts are on the same subnet, but are you able to ping each other from either host?

On Tue, Jun 5, 2018 at 3:19 PM Rae Ho (ITSC) <raeho at cuhk.edu.hk<mailto:raeho at cuhk.edu.hk>> wrote:
Dear Quan Zhou,

Thanks for your help. Rae

Router1 (/etc/bird.conf)

log syslog all;
router id 192.168.199.12;

protocol kernel {
#       learn;                  # Learn all alien routes from the kernel
        persist;                # Don't remove routes on bird shutdown
        scan time 20;           # Scan kernel routing table every 20 seconds
#       import none;            # Default is import all
        export all;             # Default is export none
#       kernel table 5;         # Kernel table to synchronize with (default: main)
}
protocol device {
        scan time 10;           # Scan interfaces every 10 seconds
}

protocol bgp {

        import all;
        export all;
        local as 76543;
        neighbor 192.168.199.13 as 87654;
}

Router1 (birdc show proto all)
BIRD 1.4.5 ready.
name     proto    table    state  since       info
kernel1  Kernel   master   up     2018-05-18
  Preference:     10
  Input filter:   ACCEPT
  Output filter:  ACCEPT
  Routes:         0 imported, 0 exported, 0 preferred
  Route change stats:     received   rejected   filtered    ignored   accepted
    Import updates:              0          0          0          0          0
    Import withdraws:            0          0        ---          0          0
    Export updates:              0          0          0        ---          0
    Export withdraws:            0        ---        ---        ---          0

device1  Device   master   up     2018-05-18
  Preference:     240
  Input filter:   ACCEPT
  Output filter:  REJECT
  Routes:         0 imported, 0 exported, 0 preferred
  Route change stats:     received   rejected   filtered    ignored   accepted
    Import updates:              0          0          0          0          0
    Import withdraws:            0          0        ---          0          0
    Export updates:              0          0          0        ---          0
    Export withdraws:            0        ---        ---        ---          0

bgp1     BGP      master   start  2018-05-18  Connect       Socket: No route to host
  Preference:     100
  Input filter:   ACCEPT
  Output filter:  ACCEPT
  Routes:         0 imported, 0 exported, 0 preferred
  Route change stats:     received   rejected   filtered    ignored   accepted
    Import updates:              0          0          0          0          0
    Import withdraws:            0          0        ---          0          0
    Export updates:              0          0          0        ---          0
    Export withdraws:            0        ---        ---        ---          0
  BGP state:          Connect
    Neighbor address: 192.168.199.13
    Neighbor AS:      87654
    Last error:       Socket: No route to host


Router2 (/etc/bird.conf)
log syslog all;
router id 192.138.199.13;

protocol kernel {
#       learn;                  # Learn all alien routes from the kernel
        persist;                # Don't remove routes on bird shutdown
        scan time 20;           # Scan kernel routing table every 20 seconds
#       import none;            # Default is import all
        export all;             # Default is export none
#       kernel table 5;         # Kernel table to synchronize with (default: main)
}

protocol device {
        scan time 10;           # Scan interfaces every 10 seconds
}

protocol bgp {
        import all;
        export all;

        local as 87654;
        neighbor 192.168.199.12 as 76543;

Router2 (birdc show proto all)
BIRD 1.4.5 ready.
name     proto    table    state  since       info
kernel1  Kernel   master   up     2018-05-18
  Preference:     10
  Input filter:   ACCEPT
  Output filter:  ACCEPT
  Routes:         0 imported, 0 exported, 0 preferred
  Route change stats:     received   rejected   filtered    ignored   accepted
    Import updates:              0          0          0          0          0
    Import withdraws:            0          0        ---          0          0
    Export updates:              0          0          0        ---          0
    Export withdraws:            0        ---        ---        ---          0

device1  Device   master   up     2018-05-18
  Preference:     240
  Input filter:   ACCEPT
  Output filter:  REJECT
  Routes:         0 imported, 0 exported, 0 preferred
  Route change stats:     received   rejected   filtered    ignored   accepted
    Import updates:              0          0          0          0          0
    Import withdraws:            0          0        ---          0          0
    Export updates:              0          0          0        ---          0
    Export withdraws:            0        ---        ---        ---          0

bgp1     BGP      master   start  2018-05-18  Active        Socket: No route to host
  Preference:     100
  Input filter:   ACCEPT
  Output filter:  ACCEPT
  Routes:         0 imported, 0 exported, 0 preferred
  Route change stats:     received   rejected   filtered    ignored   accepted
    Import updates:              0          0          0          0          0
    Import withdraws:            0          0        ---          0          0
    Export updates:              0          0          0        ---          0
    Export withdraws:            0        ---        ---        ---          0
  BGP state:          Active
    Neighbor address: 192.168.199.12
    Neighbor AS:      76543
    Start delay:      0/5
    Last error:       Socket: No route to host



From: Bird-users <bird-users-bounces at network.cz<mailto:bird-users-bounces at network.cz>> On Behalf Of Quan Zhou
Sent: Monday, June 4, 2018 6:01 PM

Cc: bird-users at network.cz<mailto:bird-users at network.cz>
Subject: Re: BIRD router/route server functions


It'd be more helpful you can provide your `bird.conf` and `birdc show proto all` if all possible.

On Mon, Jun 4, 2018 at 4:54 PM Rae Ho (ITSC) <raeho at cuhk.edu.hk<mailto:raeho at cuhk.edu.hk>> wrote:
Dear MO,
Thank you very much for your response.
Yes, I followed the sample to set up the routers but don’t why the peering session between them is not established.

Rae

From: mo at linx.net<mailto:mo at linx.net> <mo at linx.net<mailto:mo at linx.net>>
Sent: Monday, June 4, 2018 4:40 PM
To: Rae Ho (ITSC) <raeho at cuhk.edu.hk<mailto:raeho at cuhk.edu.hk>>
Cc: bird-users at network.cz<mailto:bird-users at network.cz>
Subject: Re: BIRD router/route server functions


On 4 Jun 2018, at 07:08, Rae Ho (ITSC) <raeho at cuhk.edu.hk<mailto:raeho at cuhk.edu.hk>> wrote:

Dear All,

I’m Rae of CUHK. We are exploring BIRD router/route server functions.
Now I set up 2 BIRD routers to from BGP session between them, seems It can’t form the peering (in active status).

Questions:
1.       Is there any pre-config need to be set up? (i.e. interface? Internal Subnet?)
2.       Would you mind sending me some sample configurations?
Rae


Try looking here.

https://gitlab.labs.nic.cz/labs/bird/wikis/Examples

Mo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://trubka.network.cz/pipermail/bird-users/attachments/20180605/80f944a8/attachment.html>


More information about the Bird-users mailing list