All BFD sessions are handled on single thread?

Alexander Zubkov green at qrator.net
Mon Apr 19 21:56:57 CEST 2021


Hello,

Currently, everything in the BIRD is working in the single thread. But
they actively developing multithreading version now AFAIK:
https://bird.network.cz/pipermail/bird-users/2021-March/015230.html

On Mon, Apr 19, 2021 at 7:21 PM Sema Boyko <semenboyko at gmail.com> wrote:
>
> Hi,
> I have the following configuration on one of my servers ("10.1.0.1"):
>
> protocol bfd {
>     interface "eth0" {
>                 min rx interval 200 ms;
>                 min tx interval 1000 ms;
>                 idle tx interval 1 s;
>                 multiplier 5;
>     };
>
>     neighbor 10.1.0.2;
>     neighbor 10.1.0.3;
>     neighbor 10.1.0.4;
>     ..... (here about 1000 records)
>     neighbor 10.1.3.251;
>     neighbor 10.1.3.252;
>     neighbor 10.1.3.253;
>     neighbor 10.1.3.254;
> }
>
>
> And I configured the second server ("10.1.0.2") as a neighbor with the following config:
>
> protocol bfd {
>     interface "eth0" {
>                 min rx interval 200 ms;
>                 min tx interval 1000 ms;
>                 idle tx interval 1 s;
>                 multiplier 5;
>     };
>
>     neighbor 10.1.0.1;
> }
>
> For some reason I have random session expire events on the second server and BFD sessions get UP -> DOWN, DOWN -> UP events.
> bird: bfd1: Session to 10.1.0.1 expired
> bird: bfd1: Session to 10.1.0.1 changed state from Init to Down
> bird: bfd1: Session to 10.1.0.1 changed state from Down to Init
> bird: bfd1: Session to 10.1.0.1 expired
> bird: bfd1: Session to 10.1.0.1 changed state from Init to Down
> bird: bfd1: Session to 10.1.0.1 changed state from Down to Init
>
>
> This happens only if I specify a lot of neighbors in the config. For example the following config on first server ("10.1.0.1") works fine:
>
> protocol bfd {
>     interface "eth0" {
>                 min rx interval 200 ms;
>                 min tx interval 1000 ms;
>                 idle tx interval 1 s;
>                 multiplier 5;
>     };
>
>     neighbor 10.1.0.2;
>     neighbor 10.1.0.3;
> }
>
> Looks like all BFD sessions are handled on a single thread. Could someone, please, confirm that BIRD isn't designed to handle a huge amount of BFD sessions simultaneously? Or possibly I can enable some options to handle this case in my env?


More information about the Bird-users mailing list