EVPN static IMET route on Bird 3.3.0
Hi bird users, I am currently experimenting with Bird 3.3.0 and EVPN. I do not need/want a local termination, but want to inject static EVPN routes only. Despite missing documentation (hint!), I found the necessary syntax to define mac-ip and imet routes. I also managed to manually set the required ext communities (tunnel type, MAC mobility, RT) as well as the VNI (mpls_label) in the filter. What remains open is the bgp_pmsi_tunnel attribute. According to the documentation it's not available in filters. Is there any alternative way to statically set it? Maybe a custom attribute and a binary string? Thanks, André -- André Grüneberg, Managing Director andre.grueneberg@bcix.de +49 30 2332195 42 BCIX Management GmbH Albrechtstr. 110 12103 Berlin Germany Geschäftsführer/Managing Directors: Jens Lietzmann, André Grüneberg Handelsregister: Amtsgericht Charlottenburg, HRB 143581 B
Hi again, I have tried a few things and looked at a bit of code. By now I learned from documentation that I cannot create a custom attribute -- bgp_pmsi_tunnel already exists. And I cannot assign a bytestring -- the documentation says it's not accessible in filters. Since the route attribute is of T_OPAQUE, I also cannot assign a value in the static route. The only place in the code accessing bgp_pmsi_tunnel is in evpn_announce_imet(). So it seems I will need a minimal protocol evpn in my config. Can I build one without having all the vxlan interfaces? Note: I need the router address to be another system. Thanks, André On Wed, 27 May 2026 at 17:12, André Grüneberg <andre.grueneberg@bcix.de> wrote:
Hi bird users,
I am currently experimenting with Bird 3.3.0 and EVPN. I do not need/want a local termination, but want to inject static EVPN routes only.
Despite missing documentation (hint!), I found the necessary syntax to define mac-ip and imet routes. I also managed to manually set the required ext communities (tunnel type, MAC mobility, RT) as well as the VNI (mpls_label) in the filter.
What remains open is the bgp_pmsi_tunnel attribute. According to the documentation it's not available in filters.
Is there any alternative way to statically set it? Maybe a custom attribute and a binary string?
Thanks, André
-- André Grüneberg, Managing Director andre.grueneberg@bcix.de
+49 30 2332195 42
BCIX Management GmbH Albrechtstr. 110 12103 Berlin Germany
Geschäftsführer/Managing Directors: Jens Lietzmann, André Grüneberg Handelsregister: Amtsgericht Charlottenburg, HRB 143581 B
-- André Grüneberg, Managing Director andre.grueneberg@bcix.de +49 30 2332195 42 BCIX Management GmbH Albrechtstr. 110 12103 Berlin Germany Geschäftsführer/Managing Directors: Jens Lietzmann, André Grüneberg Handelsregister: Amtsgericht Charlottenburg, HRB 143581 B
Hello André, thank you for checking out our EVPN implementation. If I remember correctly, we didn't think about injecting totally static information, and therefore I'm afraid there is no easy way around this for now. Specifically, it doesn't look possible to me to get an EVPN protocol without the VXLAN device, as it has to generate FDB records using that device. You may try changing the type from T_OPAQUE to T_BYTESTRING in proto/bgp/attrs.c (and building yourself), that should make it (for 3.3.0) accessible for setting to custom values by filters. We didn't do that simply because we want to update the filter language to systematically support structured data, and this would be yet another quirk to take care about later and possibly carry forward to far future. Maybe Ondřej has better ideas later today, let's see. I hope this helps. Happy experimenting! Maria On Thu, May 28, 2026 at 08:57:50AM +0200, André Grüneberg wrote:
Hi again,
I have tried a few things and looked at a bit of code.
By now I learned from documentation that I cannot create a custom attribute -- bgp_pmsi_tunnel already exists. And I cannot assign a bytestring -- the documentation says it's not accessible in filters. Since the route attribute is of T_OPAQUE, I also cannot assign a value in the static route.
The only place in the code accessing bgp_pmsi_tunnel is in evpn_announce_imet(). So it seems I will need a minimal protocol evpn in my config. Can I build one without having all the vxlan interfaces? Note: I need the router address to be another system.
Thanks, André
On Wed, 27 May 2026 at 17:12, André Grüneberg <andre.grueneberg@bcix.de> wrote:
Hi bird users,
I am currently experimenting with Bird 3.3.0 and EVPN. I do not need/want a local termination, but want to inject static EVPN routes only.
Despite missing documentation (hint!), I found the necessary syntax to define mac-ip and imet routes. I also managed to manually set the required ext communities (tunnel type, MAC mobility, RT) as well as the VNI (mpls_label) in the filter.
What remains open is the bgp_pmsi_tunnel attribute. According to the documentation it's not available in filters.
Is there any alternative way to statically set it? Maybe a custom attribute and a binary string?
Thanks, André
-- André Grüneberg, Managing Director andre.grueneberg@bcix.de
+49 30 2332195 42
BCIX Management GmbH Albrechtstr. 110 12103 Berlin Germany
Geschäftsführer/Managing Directors: Jens Lietzmann, André Grüneberg Handelsregister: Amtsgericht Charlottenburg, HRB 143581 B
-- André Grüneberg, Managing Director andre.grueneberg@bcix.de +49 30 2332195 42
BCIX Management GmbH Albrechtstr. 110 12103 Berlin Germany
Geschäftsführer/Managing Directors: Jens Lietzmann, André Grüneberg Handelsregister: Amtsgericht Charlottenburg, HRB 143581 B
-- Maria Matejka (she/her) | BIRD Team Leader | CZ.NIC, z.s.p.o.
Dear Maria, dear all, I believe, I managed to make it work. Before starting bird: ip link add name vx7 type vxlan id $VNI local $ROUTER dstport 4789 ip link set vx7 up bird.conf: eth table t_eth; evpn table t_evpn; protocol evpn p_ixpect01 { evpn { table t_evpn; }; eth { table t_eth; }; rd my_ip:100; route target (rt, 10, 100); encapsulation vxlan { tunnel device "vx7"; }; } So it takes a whole protocol to inject a static entry -- with the limitation of one IMET route per VNI. BTW: In case the vxlan Interface does not exist, Bird 3.3.0 on Ubuntu 26.04 does crash with a segfault in libc: kernel: bird[236863]: segfault at 10 ip 00007963a6b9a1af sp 00007ffe6a8cda38 error 4 in libc.so.6[19a1af,7963a6a28000+198000] likely on CPU 1 (core 2, socket 0) kernel: Code: 2e 0f 1f 84 00 00 00 00 00 66 90 f3 0f 1e fa c4 41 01 ef ff 89 f8 09 f0 c1 e0 14 3d 00 00 00 f8 0f 87 25 03 00 00 c5 fe 6f 07 <c5> fd 74 0e c5 85 74 d0 c5 ed df c9 c5 fd d7 c9 ff c1 74 5d f3 0f Is this considered a bug? ;) Best wishes, André On Thu, 28 May 2026 at 10:06, Maria Matejka <maria.matejka@nic.cz> wrote:
Hello André,
thank you for checking out our EVPN implementation. If I remember correctly, we didn’t think about injecting totally static information, and therefore I’m afraid there is no easy way around this for now. Specifically, it doesn’t look possible to me to get an EVPN protocol without the VXLAN device, as it has to generate FDB records using that device.
You may try changing the type from T_OPAQUE to T_BYTESTRING in proto/bgp/attrs.c (and building yourself), that should make it (for 3.3.0) accessible for setting to custom values by filters. We didn’t do that simply because we want to update the filter language to systematically support structured data, and this would be yet another quirk to take care about later and possibly carry forward to far future.
Maybe Ondřej has better ideas later today, let’s see.
I hope this helps. Happy experimenting! Maria
On Thu, May 28, 2026 at 08:57:50AM +0200, André Grüneberg wrote:
Hi again,
I have tried a few things and looked at a bit of code.
By now I learned from documentation that I cannot create a custom attribute – bgp_pmsi_tunnel already exists. And I cannot assign a bytestring – the documentation says it’s not accessible in filters. Since the route attribute is of T_OPAQUE, I also cannot assign a value in the static route.
The only place in the code accessing bgp_pmsi_tunnel is in evpn_announce_imet(). So it seems I will need a minimal protocol evpn in my config. Can I build one without having all the vxlan interfaces? Note: I need the router address to be another system.
Thanks, André
On Wed, 27 May 2026 at 17:12, André Grüneberg andre.grueneberg@bcix.de wrote:
Hi bird users,
I am currently experimenting with Bird 3.3.0 and EVPN. I do not need/want a local termination, but want to inject static EVPN routes only.
Despite missing documentation (hint!), I found the necessary syntax to define mac-ip and imet routes. I also managed to manually set the required ext communities (tunnel type, MAC mobility, RT) as well as the VNI (mpls_label) in the filter.
What remains open is the bgp_pmsi_tunnel attribute. According to the documentation it’s not available in filters.
Is there any alternative way to statically set it? Maybe a custom attribute and a binary string?
Thanks, André
– André Grüneberg, Managing Director andre.grueneberg@bcix.de
+49 30 2332195 42
BCIX Management GmbH Albrechtstr. 110 12103 Berlin Germany
Geschäftsführer/Managing Directors: Jens Lietzmann, André Grüneberg Handelsregister: Amtsgericht Charlottenburg, HRB 143581 B
– André Grüneberg, Managing Director andre.grueneberg@bcix.de +49 30 2332195 42
BCIX Management GmbH Albrechtstr. 110 12103 Berlin Germany
Geschäftsführer/Managing Directors: Jens Lietzmann, André Grüneberg Handelsregister: Amtsgericht Charlottenburg, HRB 143581 B
– Maria Matejka (she/her) | BIRD Team Leader | CZ.NIC, z.s.p.o.
-- André Grüneberg, Managing Director andre.grueneberg@bcix.de +49 30 2332195 42 BCIX Management GmbH Albrechtstr. 110 12103 Berlin Germany Geschäftsführer/Managing Directors: Jens Lietzmann, André Grüneberg Handelsregister: Amtsgericht Charlottenburg, HRB 143581 B
Dear André, On Thu, May 28, 2026 at 12:00:50PM +0200, André Grüneberg wrote:
Before starting bird: ip link add name vx7 type vxlan id $VNI local $ROUTER dstport 4789 ip link set vx7 up
That means you indeed have the vxlan interface which you wanted to not have, but whatever, yes, this works.
bird.conf: eth table t_eth; evpn table t_evpn; protocol evpn p_ixpect01 { evpn { table t_evpn; }; eth { table t_eth; }; rd my_ip:100; route target (rt, 10, 100); encapsulation vxlan { tunnel device "vx7"; }; }
So it takes a whole protocol to inject a static entry -- with the limitation of one IMET route per VNI.
That looks like a viable yet kinda cursed solution. We'll definitely look into possibilities on how to make it less cursed.
BTW: In case the vxlan Interface does not exist, Bird 3.3.0 on Ubuntu 26.04 does crash with a segfault in libc:
kernel: bird[236863]: segfault at 10 ip 00007963a6b9a1af sp 00007ffe6a8cda38 error 4 in libc.so.6[19a1af,7963a6a28000+198000] likely on CPU 1 (core 2, socket 0) kernel: Code: 2e 0f 1f 84 00 00 00 00 00 66 90 f3 0f 1e fa c4 41 01 ef ff 89 f8 09 f0 c1 e0 14 3d 00 00 00 f8 0f 87 25 03 00 00 c5 fe 6f 07 <c5> fd 74 0e c5 85 74 d0 c5 ed df c9 c5 fd d7 c9 ff c1 74 5d f3 0f
Is this considered a bug? ;)
Congratulations, you have found a bug! We'll let you know as soon as we know more about that. Internal reference: #423 Happy routing! Maria -- Maria Matejka (she/her) | BIRD Team Leader | CZ.NIC, z.s.p.o.
Ah, I spotted it yesterday evening while testing in lab. If the configuration is there at start it crashes, but commenting it, starting bird, uncommenting it and reloading bird works. I didn’t had time to spin gdb yet :p On Thu 28 May 2026 13:19:44 GMT, Maria Matejka via Bird-users wrote:
Dear André,
On Thu, May 28, 2026 at 12:00:50PM +0200, André Grüneberg wrote:
Before starting bird: ip link add name vx7 type vxlan id $VNI local $ROUTER dstport 4789 ip link set vx7 up
That means you indeed have the vxlan interface which you wanted to not have, but whatever, yes, this works.
bird.conf: eth table t_eth; evpn table t_evpn; protocol evpn p_ixpect01 { evpn { table t_evpn; }; eth { table t_eth; }; rd my_ip:100; route target (rt, 10, 100); encapsulation vxlan { tunnel device "vx7"; }; }
So it takes a whole protocol to inject a static entry -- with the limitation of one IMET route per VNI.
That looks like a viable yet kinda cursed solution. We'll definitely look into possibilities on how to make it less cursed.
BTW: In case the vxlan Interface does not exist, Bird 3.3.0 on Ubuntu 26.04 does crash with a segfault in libc:
kernel: bird[236863]: segfault at 10 ip 00007963a6b9a1af sp 00007ffe6a8cda38 error 4 in libc.so.6[19a1af,7963a6a28000+198000] likely on CPU 1 (core 2, socket 0) kernel: Code: 2e 0f 1f 84 00 00 00 00 00 66 90 f3 0f 1e fa c4 41 01 ef ff 89 f8 09 f0 c1 e0 14 3d 00 00 00 f8 0f 87 25 03 00 00 c5 fe 6f 07 <c5> fd 74 0e c5 85 74 d0 c5 ed df c9 c5 fd d7 c9 ff c1 74 5d f3 0f
Is this considered a bug? ;)
Congratulations, you have found a bug! We'll let you know as soon as we know more about that. Internal reference: #423
Happy routing! Maria
-- Maria Matejka (she/her) | BIRD Team Leader | CZ.NIC, z.s.p.o.
participants (3)
-
Alarig Le Lay -
André Grüneberg -
Maria Matejka