Skip to content

Conversation

@chiragshah6
Copy link
Member

@chiragshah6 chiragshah6 commented Nov 25, 2025

Add comprehensive IPv6 VTEP support throughout the EVPN codebase, enabling EVPN to work with IPv6 tunnel endpoints while maintaining full backward compatibility with IPv4 VTEPs.

bgpd:
- Update EVPN data structures to use struct ipaddr instead of struct in_addr for VTEP addresses
- Add IPv6 support for remote ES VTEP structures
- Fix IPv6 next-hop encoding/decoding in BGP UPDATE messages for EVPN routes
- Update all display/logging to use %pIA format for VTEP addresses
- Update route processing and handling for IPv6 VTEP scenarios
Zebra

  • IPv6 VTEP support for bgp to zebra sync
  • MH operational command to have IPv6 VTEP support

tests:

  • New EVPN MH test which uses service integrated-vtysh-config, SVD, BGP numbered underlay fabric
torm11# show bgp l2vpn evpn es
ES Flags: B - bypass, L local, R remote, I inconsistent
VTEP Flags: E ESR/Type-4, A active nexthop
ESI                            Flags RD                    #VNIs    VTEPs
03:44:38:39:ff:ff:01:00:00:01  LR    10.0.0.15:3           1        2001:db8:100::16(EA)
03:44:38:39:ff:ff:01:00:00:02  LR    10.0.0.15:4           1        2001:db8:100::16(EA)
03:44:38:39:ff:ff:02:00:00:01  R     (null)                1        2001:db8:100::17(A),2001:db8:100::18(A)
03:44:38:39:ff:ff:02:00:00:02  R     (null)                1        2001:db8:100::17(A),2001:db8:100::18(A)
torm11# show bgp l2vpn evpn es 03:44:38:39:ff:ff:01:00:00:01
ESI: 03:44:38:39:ff:ff:01:00:00:01
 Type: LR
 RD: 10.0.0.15:3
 Originator-IP: 2001:db8:100::15
 Local ES DF preference: 32767
 VNI Count: 1
 Remote VNI Count: 1
 VRF Count: 0
 MACIP EVI Path Count: 2
 MACIP Global Path Count: 6
 Inconsistent VNI VTEP Count: 0
 Inconsistencies: -
 Fragments:
  10.0.0.15:3 EVIs: 1
 VTEPs:
  2001:db8:100::16 flags: EA df_alg: preference df_pref: 60000
torm11# show evpn es
Type: B bypass, L local, R remote, N non-DF
ESI                            Type ES-IF                 VTEPs
03:44:38:39:ff:ff:01:00:00:01  LRN  hostbond1             2001:db8:100::16
03:44:38:39:ff:ff:01:00:00:02  LR   hostbond2             2001:db8:100::16
03:44:38:39:ff:ff:02:00:00:01  R    -                     2001:db8:100::17,2001:db8:100::18
03:44:38:39:ff:ff:02:00:00:02  R    -                     2001:db8:100::17,2001:db8:100::18
torm11# show evpn es 03:44:38:39:ff:ff:01:00:00:01
ESI: 03:44:38:39:ff:ff:01:00:00:01
 Type: Local,Remote
 Interface: hostbond1
 State: up
 Bridge port: yes
 Ready for BGP: yes
 VNI Count: 1
 MAC Count: 3
 DF status: non-df
 DF preference: 32767
 Nexthop group: 536870913
 VTEPs:
     2001:db8:100::16 df_alg: preference df_pref: 60000 nh: 268435459
torm11# show bgp l2vpn evpn es-evi 
Flags: L local, R remote, I inconsistent
VTEP-Flags: E EAD-per-ES, V EAD-per-EVI
VNI      ESI                            Flags VTEPs
1000     03:44:38:39:ff:ff:01:00:00:01  LR    2001:db8:100::16(EV)
1000     03:44:38:39:ff:ff:01:00:00:02  LR    2001:db8:100::16(EV)
1000     03:44:38:39:ff:ff:02:00:00:01  R     2001:db8:100::17(EV),2001:db8:100::18(EV)
1000     03:44:38:39:ff:ff:02:00:00:02  R     2001:db8:100::17(EV),2001:db8:100::18(EV)

Signed-off-by: Jared Mauch [email protected]
Signed-off-by: Manpreet Kaur [email protected]
Signed-off-by: Chirag Shah [email protected]

@frrbot frrbot bot added bgp bugfix libfrr tests Topotests, make check, etc zebra labels Nov 25, 2025
@chiragshah6 chiragshah6 force-pushed the evpnv6mh_1 branch 2 times, most recently from d6fbcd6 to c8c3dc3 Compare November 25, 2025 05:15
@chiragshah6 chiragshah6 changed the title *:EVPN over IPv6 underlay fabric - Multi homed *:EVPN IPv6 VTEP support - Multihomed Nov 25, 2025
@chiragshah6 chiragshah6 marked this pull request as ready for review November 25, 2025 15:30
@riw777 riw777 self-requested a review November 25, 2025 16:26
@chiragshah6 chiragshah6 force-pushed the evpnv6mh_1 branch 3 times, most recently from d4b8599 to 1d0526f Compare November 29, 2025 21:22
@frrbot frrbot bot added the documentation label Nov 29, 2025
@github-actions
Copy link

github-actions bot commented Dec 4, 2025

This pull request has conflicts, please resolve those before we can evaluate the pull request.

RFC alignment of Type4 route size to accomodate v6 nh
BGP_EVPN_TYPE4_V6_PSIZE

Signed-off-by: Chirag Shah <[email protected]>
Signed-off-by: Jared Mauch <[email protected]>
bgp_evpn_remote_es_evi_add/ bgp_evpn_remote_es_evi_del
were incorrectly using p->prefix.ead_addr.ip directly,
prefix (prefix in global table has IP zeroed out),
extracts the vtep_ip from the BGP path attributes

Signed-off-by: Chirag Shah <[email protected]>
Signed-off-by: Jared Mauch <[email protected]>
chiragshah6 and others added 21 commits December 6, 2025 09:58
Signed-off-by: Chirag Shah <[email protected]>
Signed-off-by: Jared Mauch <[email protected]>
Signed-off-by: Chirag Shah <[email protected]>
Signed-off-by: Jared Mauch <[email protected]>
The prefixlen is used for debug and cli purpose,
EVPNv6 add ipv6 address in EVPN prefix which spill over
current prefixlen limit.

Before:
2025/09/29 19:02:12.474562 BGP: [WTJQB-H1EZQ] default (0): Installing EVPN
[1]:[4294967295]:[03:44:38:39:ff:ff:01:00:00:01]:[128]:[2001:c001:ff:f00d::4]:[   <<<<
route in VNI 1000 IP/MAC table

After:
2025/09/29 19:26:13.025185 BGP: [WTJQB-H1EZQ] default (0): Installing EVPN
[1]:[4294967295]:[03:44:38:39:ff:ff:01:00:00:01]:[128]:[2001:c001:ff:f00d::4]:[0]
route in VNI 1000 IP/MAC table

Signed-off-by: Chirag Shah <[email protected]>
Signed-off-by: Chirag Shah <[email protected]>
Signed-off-by: Jared Mauch <[email protected]>
Signed-off-by: Chirag Shah <[email protected]>
Signed-off-by: Jared Mauch <[email protected]>
This test is converted to from bgp_evpn_mh
to use `service integrated-vtysh-config` along
with BGP numbered underlay fabric with IPv6 VTEP.

IPv6 VTEP address, BGP GUA address
IPv4: 10.0.0.x/32 and related underlay prefixes are from 10.0.0.0/8,
which is RFC 1918 private space and appropriate for internal tests.
IPv6: all the 2001:db8:... prefixes are from 2001:db8::/32, the RFC 3849
documentation block, explicitly reserved for examples and non-production
use.

Signed-off-by: Chirag Shah <[email protected]>
On torm-11 load the frr.conf using frr-reload script.
For this pass to topogen a flag to skip loading
vtysh -f frr.conf file for a given DUT based on the flag.

Signed-off-by: Chirag Shah <[email protected]>
When configuring interface ip from frr.conf using
frr-reload there is a timing involved bgp is not
receiving fast enough either ipv4 or ipv6 address,
which leads to an issue where ipv4 route over ipv6
bgp peer, uses the v4 mapped v6 address and route
becomes unreachable at the remote bgp peer end.

To fix the timing configure ip address using
linux iproute2 commands.

Signed-off-by: Chirag Shah <[email protected]>
Router instance to provide a knob to skip
flushing all interface ips when router instance
is created.

Check bgp peer state and underlay network
right after torm-11 configured using
frr-reload script.

Signed-off-by: Chirag Shah <[email protected]>
UT:
frr_bgp:evpn_mh_local_es_add_zrecv {'esi': '03:44:38:39:ff:ff:01:00:00:01', 'vtep': '2001:c001:ff:f00d::3', 'active': 0, 'bypass': 0, 'df_pref': 32767}
frr_bgp:evpn_mh_local_ead_es_evi_route_upd {'esi': '03:44:38:39:ff:ff:01:00:00:01', 'vni': 1000, 'route_type': 1, 'vtep_v4': '0.0.0.0', 'vtep_v6': '2001:c001:ff:f00d::3'}
frr_bgp:evpn_bum_vtep_zsend {'action': 'add', 'vni': 1009, 'vtep': '2001:c001:ff:f00d::4'}
frr_bgp:evpn_mh_local_ead_es_evi_route_del {'esi': '03:44:38:39:ff:ff:01:00:00:03', 'vni': 1009, 'route_type': 1, 'vtep': '2001:c001:ff:f00d::3'}
frr_bgp:evpn_mh_es_evi_vtep_add {'esi': '03:44:38:39:ff:ff:01:00:00:03', 'vni': 1009, 'vtep': '2001:c001:ff:f00d::4', 'ead_es': 0}
frr_bgp:evpn_mh_vtep_zsend {'action': 'add', 'esi': '03:44:38:39:ff:ff:01:00:00:02', 'vtep': '2001:c001:ff:f00d::5'}
frr_bgp:evpn_mh_nh_zsend {'nhg': 73529414, 'vtep': '2001:c001:ff:f00d::5', 'svi': 29}
frr_bgp:evpn_mh_es_evi_vtep_del {'esi': '03:44:38:39:ff:ff:01:00:00:01', 'vni': 1005, 'vtep': '2001:c001:ff:f00d::4', 'ead_es': 0}

Signed-off-by: Manpreet Kaur <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants