MPLS-based EVPN IRB Provides Layer-3 VPN for IPv6 Locations
Table of Contents
- What is MPLS Layer-3 VPN 6VPE with EVPN IRB? ‹
- Configuring EVPN IRB L3VPN for IPv6 ‹
- Packet capture EVPN Route Type 5 with IPv6 prefix ‹
- Download section ‹
What is MPLS Layer-3 VPN 6VPE with EVPN IRB?
A Layer-3 VPN 6VPE solution provides connectivity for IPv6-only customer sites across an IPv4-only MPLS core network. The Provider Edge (PE) routers are dual stack and have interfaces enabled with IPv4/IPv6 address-families. The PE routers establish Multiprotocol BGP (MP-BGP) neighborships to exchange site-local IPv6 prefixes. Meanwhile, the MPLS core uses an IPv4 IGP (OSPF or IS-IS) to provide a transport backbone network between the PE routers.
EVPN IRB together with Segment Routing delivers multiple benefits compared to MPLS 6VPE VPNv6 with LDP/RSVP. In addition to creating L2VPNs, EVPN IRB leverages the flexibility of MP-BGP to advertise IPv4 and/or IPv6 routes. The following output shows a Provider Edge router advertising IPv6 prefixes using the EVPN Route Type 5.
PE1#show ip bgp l2vpn evpn neighbors 8.8.8.8 advertised-routes | beg Ne Network Next Hop Metric LocPrf Weight Path Route Distinguisher: 6.6.6.6:100 *> [2][6.6.6.6:100][0][48][5254000EA1C3][0][*]/20 :: 32768 ? *> [3][6.6.6.6:100][0][32][6.6.6.6]/17 :: 32768 ? Route Distinguisher: 65100:2 (default for vrf Gold) *> [5][65100:2][0][64][2001:DB8:A2::]/29 2001:DB8:E2::2 0 0 65002 i *> [5][65100:2][0][64][2001:DB8:E2::]/29 :: 0 32768 i Total number of prefixes 4 PE2#show ipv6 cef vrf Gold 2001:DB8:A2::/64 2001:DB8:A2::/64 nexthop 10.1.0.2 GigabitEthernet2 label 16006-(local:16006) 604
Configuring EVPN IRB L3VPN for IPv6
In the following example topology IPv6-only sites in VRF Gold are connected through an IPv4-only MPLS core network. The PE routers R2 and R6 are dual-stack IPv4 and IPv6. The CE-facing Bridge Domain Interface (BDI) on the PE routers is assigned to VRF Gold and uses an IPv6 address to establish an eBGP neighborship with the neighboring CE device. The MPLS core facing interface on the PE routers is assigned an IPv4 address and uses OSPF in the backbone area 0 together with Segment Routing (SR).
The MPLS core network uses IPv4-only, and Segment Routing is configured to provide a Label Switched Path (LSP) between the PE routers. SR assigns a transport label from the Global Block (SRGB) 16000 - 23999 to encapsulate packets in the MPLS core network.
Meanwhile, a VPN service label is assigned with EVPN IRB to provide a Layer-3 VPN architecture in the address-family IPv6. PE R2 assigns VPN service labels in the range 200 - 299, and PE R6 uses 600 - 699.
Configuration:
R2 (PE)
R2#show run | sec ^ipv6 ipv6 unicast-routing R2#show run | sec ^mpls mpls label range 200 299 R2#show run | sec ^segment segment-routing mpls ! connected-prefix-sid-map address-family ipv4 2.2.2.2/32 index 2 range 1 exit-address-family ! R2#show run | sec ^vrf vrf definition Gold rd 65100:1 ! address-family ipv6 route-target export 65100:1 stitching route-target import 65100:2 stitching exit-address-family R2#show run int Lo10 | sec int interface Loopback10 ip address 2.2.2.2 255.255.255.255 R2#show run int Gi1 | sec int interface GigabitEthernet1 description ** to CE R1 ** no ip address negotiation auto no mop enabled no mop sysid service instance 5 ethernet encapsulation untagged ! R2#show run int Gi2 | sec int interface GigabitEthernet2 description ** to R3 ** ip address 10.1.0.1 255.255.255.252 ip ospf network point-to-point negotiation auto no mop enabled no mop sysid R2#show run int BDI 10 | sec int interface BDI10 description ** to CE R1 in VRF Gold ** vrf forwarding Gold no ip address ipv6 address 2001:DB8:E1::1/64 no mop enabled no mop sysid R2#show run | sec ^l2vpn l2vpn evpn replication-type ingress mpls label mode per-ce router-id Loopback10 l2vpn evpn instance 100 vlan-based R2#show run | sec ^bridge-domain bridge-domain 10 member GigabitEthernet1 service-instance 5 member evpn-instance 100 R2#show run | sec ^router router ospf 10 router-id 2.2.2.2 segment-routing area 0 mpls segment-routing mpls network 2.2.2.2 0.0.0.0 area 0 network 10.1.0.0 0.0.0.3 area 0 router bgp 65100 bgp router-id 2.2.2.2 bgp log-neighbor-changes neighbor 8.8.8.8 remote-as 65100 neighbor 8.8.8.8 update-source Loopback10 ! address-family l2vpn evpn neighbor 8.8.8.8 activate neighbor 8.8.8.8 send-community both exit-address-family ! address-family ipv6 vrf Gold advertise l2vpn evpn network 2001:DB8:E1::/64 neighbor 2001:DB8:E1::2 remote-as 65001 neighbor 2001:DB8:E1::2 activate exit-address-family
R6 (PE)
R6#show run | sec ^ipv6 ipv6 unicast-routing R6#show run | sec ^mpls mpls label range 600 699 R6#show run | sec ^segment segment-routing mpls ! connected-prefix-sid-map address-family ipv4 6.6.6.6/32 index 6 range 1 exit-address-family ! R6#show run | sec ^vrf vrf definition Gold rd 65100:2 ! address-family ipv6 route-target export 65100:2 stitching route-target import 65100:1 stitching exit-address-family R6#show run int Lo10 | sec int interface Loopback10 ip address 6.6.6.6 255.255.255.255 R6#show run int Gi1 | sec int interface GigabitEthernet1 description ** to CE R7 ** no ip address negotiation auto no mop enabled no mop sysid service instance 5 ethernet encapsulation untagged ! R6#show run int Gi2 | sec int interface GigabitEthernet2 description ** to R5 ** ip address 10.4.0.1 255.255.255.252 ip ospf network point-to-point negotiation auto no mop enabled no mop sysid R6#show run int BDI 10 | sec int interface BDI10 description ** to CE R7 in VRF Gold ** vrf forwarding Gold no ip address ipv6 address 2001:DB8:E2::1/64 no mop enabled no mop sysid R6#show run | sec ^l2vpn l2vpn evpn replication-type ingress mpls label mode per-ce router-id Loopback10 l2vpn evpn instance 100 vlan-based R6#show run | sec ^bridge-domain bridge-domain 10 member GigabitEthernet1 service-instance 5 member evpn-instance 100 R6#show run | sec ^router router ospf 10 router-id 6.6.6.6 segment-routing area 0 mpls segment-routing mpls network 6.6.6.6 0.0.0.0 area 0 network 10.4.0.0 0.0.0.3 area 0 router bgp 65100 bgp router-id 6.6.6.6 bgp log-neighbor-changes neighbor 8.8.8.8 remote-as 65100 neighbor 8.8.8.8 update-source Loopback10 ! address-family l2vpn evpn neighbor 8.8.8.8 activate neighbor 8.8.8.8 send-community both exit-address-family ! address-family ipv6 vrf Gold advertise l2vpn evpn network 2001:DB8:E2::/64 neighbor 2001:DB8:E2::2 remote-as 65002 neighbor 2001:DB8:E2::2 activate exit-address-family
R8 (BGP RR)
R8#show run int Lo10 | sec int interface Loopback10 ip address 8.8.8.8 255.255.255.255 R8#show run int Gi0/0 | sec int interface GigabitEthernet0/0 description ** to R4 ** ip address 10.5.0.2 255.255.255.252 ip ospf network point-to-point duplex auto speed auto media-type rj45 R8#show run | sec ^router router ospf 10 router-id 8.8.8.8 network 8.8.8.8 0.0.0.0 area 0 network 10.5.0.0 0.0.0.3 area 0 router bgp 65100 bgp router-id 8.8.8.8 bgp log-neighbor-changes neighbor 2.2.2.2 remote-as 65100 neighbor 2.2.2.2 update-source Loopback10 neighbor 6.6.6.6 remote-as 65100 neighbor 6.6.6.6 update-source Loopback10 ! address-family l2vpn evpn neighbor 2.2.2.2 activate neighbor 2.2.2.2 send-community both neighbor 2.2.2.2 route-reflector-client neighbor 6.6.6.6 activate neighbor 6.6.6.6 send-community both neighbor 6.6.6.6 route-reflector-client exit-address-family
R3
R3#show run | sec ^segment segment-routing mpls ! connected-prefix-sid-map address-family ipv4 3.3.3.3/32 index 3 range 1 exit-address-family ! R3#show run int Lo10 | sec int interface Loopback10 ip address 3.3.3.3 255.255.255.255 R3#show run int Gi1 | sec int interface GigabitEthernet1 description ** to PE R2 ** ip address 10.1.0.2 255.255.255.252 ip ospf network point-to-point negotiation auto no mop enabled no mop sysid R3#show run int Gi2 | sec int interface GigabitEthernet2 description ** to R4 ** ip address 10.2.0.1 255.255.255.252 ip ospf network point-to-point negotiation auto no mop enabled no mop sysid R3#show run | sec ^router router ospf 10 router-id 3.3.3.3 segment-routing area 0 mpls segment-routing mpls network 3.3.3.3 0.0.0.0 area 0 network 10.1.0.0 0.0.0.3 area 0 network 10.2.0.0 0.0.0.3 area 0
R4
R4#show run | sec ^segment segment-routing mpls ! connected-prefix-sid-map address-family ipv4 4.4.4.4/32 index 4 range 1 exit-address-family ! R4#show run int Lo10 | sec int interface Loopback10 ip address 4.4.4.4 255.255.255.255 R4#show run int Gi1 | sec int interface GigabitEthernet1 description ** to R3 ** ip address 10.2.0.2 255.255.255.252 ip ospf network point-to-point negotiation auto no mop enabled no mop sysid R4#show run int Gi2 | sec int interface GigabitEthernet2 description ** to R5 ** ip address 10.3.0.1 255.255.255.252 ip ospf network point-to-point negotiation auto no mop enabled no mop sysid R4#show run int Gi3 | sec int interface GigabitEthernet3 description ** to BGP RR R8 ** ip address 10.5.0.1 255.255.255.252 ip ospf network point-to-point negotiation auto no mop enabled no mop sysid R4#show run | sec ^router router ospf 10 router-id 4.4.4.4 segment-routing area 0 mpls segment-routing mpls network 4.4.4.4 0.0.0.0 area 0 network 10.2.0.0 0.0.0.3 area 0 network 10.3.0.0 0.0.0.3 area 0 network 10.5.0.0 0.0.0.3 area 0
R1 (CE)
R1#show run | sec ^ipv6 unicast ipv6 unicast-routing R1#show run | sec ^vrf vrf definition Gold rd 1:1 ! address-family ipv6 exit-address-family R1#show run int Gi0/0 | sec int interface GigabitEthernet0/0 description ** to Host1 ** no ip address duplex auto speed auto media-type rj45 R1#show run int Gi0/0.1 | sec int interface GigabitEthernet0/0.1 description ** to Host1 in VRF Gold ** encapsulation dot1Q 1 native vrf forwarding Gold ipv6 address 2001:DB8:A1::2/64 R1#show run int Gi0/1 | sec int interface GigabitEthernet0/1 description ** to PE R2 ** no ip address duplex auto speed auto media-type rj45 R1#show run int Gi0/1.1 | sec int interface GigabitEthernet0/1.1 description ** to PE R2 in VRF Gold ** encapsulation dot1Q 1 native vrf forwarding Gold ipv6 address 2001:DB8:E1::2/64 R1#show run | sec ^router router bgp 65001 bgp router-id 1.1.1.1 bgp log-neighbor-changes ! address-family ipv6 vrf Gold network 2001:DB8:A1::/64 neighbor 2001:DB8:E1::1 remote-as 65100 neighbor 2001:DB8:E1::1 activate exit-address-family
R7 (CE)
R7#show run | sec ^ipv6 unicast ipv6 unicast-routing R7#show run | sec ^vrf vrf definition Gold rd 1:1 ! address-family ipv6 exit-address-family R7#show run int Gi0/0 | sec int interface GigabitEthernet0/0 description ** to Host2 ** no ip address duplex auto speed auto media-type rj45 R7#show run int Gi0/0.1 | sec int interface GigabitEthernet0/0.1 description ** to Host2 in VRF Gold ** encapsulation dot1Q 1 native vrf forwarding Gold ipv6 address 2001:DB8:A2::2/64 R7#show run int Gi0/1 | sec int interface GigabitEthernet0/1 description ** to PE R6 ** no ip address duplex auto speed auto media-type rj45 R7#show run int Gi0/1.1 | sec int interface GigabitEthernet0/1.1 description ** to PE R6 in VRF Gold ** encapsulation dot1Q 1 native vrf forwarding Gold ipv6 address 2001:DB8:E2::2/64 R7#show run | sec ^router router bgp 65002 bgp router-id 7.7.7.7 bgp log-neighbor-changes ! address-family ipv6 vrf Gold network 2001:DB8:A2::/64 neighbor 2001:DB8:E2::1 remote-as 65100 neighbor 2001:DB8:E2::1 activate exit-address-family
Host1
Host1#show run int Gi0/0 | sec int interface GigabitEthernet0/0 description ** to CE R1 ** no ip address duplex auto speed auto media-type rj45 ipv6 address 2001:DB8:A1::1/64 Host1#show run | sec ^ipv6 route ipv6 route ::/0 2001:DB8:A1::2
Host1#ping 2001:DB8:A2::1 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 2001:DB8:A2::1, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 89/90/91 ms « Host1 (Site 1) can reach Host2 (Site 2) Host1#trace 2001:DB8:A2::1 Type escape sequence to abort. Tracing the route to 2001:DB8:A2::1 1 2001:DB8:A1::2 2 msec 2 msec 2 msec 2 2001:DB8:E1::1 7 msec 2 msec 2 msec 3 ::FFFF:10.1.0.2 [MPLS: Labels 16006/604 Exp 0] 8 msec 5 msec 5 msec « MPLS label stack is used to transport IPv6 traffic 4 ::FFFF:10.2.0.2 [MPLS: Labels 16006/604 Exp 0] 7 msec 6 msec 5 msec 5 ::FFFF:10.3.0.2 [MPLS: Labels 16006/604 Exp 0] 16 msec 6 msec 5 msec 6 2001:DB8:E2::1 [MPLS: Label 604 Exp 0] 5 msec 5 msec 4 msec « VPN service label assigned by PE R6 7 2001:DB8:E2::2 5 msec 6 msec 6 msec 8 2001:DB8:A2::1 6 msec 7 msec 5 msec Host2#trace 2001:DB8:A1::1 Type escape sequence to abort. Tracing the route to 2001:DB8:A1::1 1 2001:DB8:A2::2 1 msec 2 msec 2 msec 2 2001:DB8:E2::1 23 msec 22 msec 23 msec 3 ::FFFF:10.4.0.2 [MPLS: Labels 16002/204 Exp 0] 91 msec 90 msec 89 msec 4 ::FFFF:10.3.0.1 [MPLS: Labels 16002/204 Exp 0] 92 msec 90 msec 90 msec 5 ::FFFF:10.2.0.1 [MPLS: Labels 16002/204 Exp 0] 89 msec 89 msec 90 msec 6 2001:DB8:E1::1 [MPLS: Label 204 Exp 0] 77 msec 72 msec 68 msec 7 2001:DB8:E1::2 91 msec 90 msec 90 msec 8 2001:DB8:A1::1 90 msec 91 msec 91 msec
As visible in the above outputs, Host1 can reach Host2 using the IPv4-only MPLS core network. Essentially, IPv6 traffic is tunneled across the network using MPLS encapsulation. The top label (16006 and 16002 respectively) is the transport label which is assigned by Segment Routing. The bottom label (604 and 204) is the VPN service label which is advertised by the PE routers using EVPN IRB.
The IPv6 prefixes are advertised with EVPN IRB using the Route Type 5 encoded in Multiprotocol-BGP (MP-BGP) Update messages. These messages are originated by the PE routers and received through the BGP Route Reflector R8. The following output is taken from PE R2 and shows the IPv6 (L3VPN) prefixes received through EVPN IRB.
R2#show ip bgp l2vpn evpn all sum | beg Ne Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd 8.8.8.8 4 65100 165 136 23 0 0 01:54:14 4 « PE R2 receives four EVPN prefixes from the RR R8 R2#show ip bgp l2vpn evpn rd 65100:2 | beg Ne Network Next Hop Metric LocPrf Weight Path Route Distinguisher: 65100:2 *>i [5][65100:2][0][64][2001:DB8:A2::]/29 « EVPN Route Type 5 with IPv6 prefix 6.6.6.6 0 100 0 65002 i *>i [5][65100:2][0][64][2001:DB8:E2::]/29 6.6.6.6 0 100 0 i R2#show ip bgp l2vpn evpn rd 65100:2 route-type 5 0 2001:DB8:A2:: 64 BGP routing table entry for [5][65100:2][0][64][2001:DB8:A2::]/29, version 21 « Site 2 IPv6 prefix received through EVPN IRB Paths: (1 available, best #1, table EVPN-BGP-Table) Not advertised to any peer Refresh Epoch 4 65002 6.6.6.6 (metric 5) (via default) from 8.8.8.8 (8.8.8.8) Origin IGP, metric 0, localpref 100, valid, internal, best EVPN ESI: 00000000000000000000, Gateway Address: ::, VNI Label 0, MPLS VPN Label 605 « VPN service label assigned by PE R6 Extended Community: RT:65100:2 Originator: 6.6.6.6, Cluster list: 8.8.8.8 « PE R6 originates this prefix rx pathid: 0, tx pathid: 0x0 net: 0x7FDE0A6E1938, path: 0x7FDE3A996D20, pathext: 0x7FDE3AA48D78 flags: net: 0x0, path: 0x3, pathext: 0x81 attribute: 0x7FDE3A986B90, ref: 2 Updated on May 12 2024 13:36:23 UTC
The following output is taken from the BGP RR R8 and shows all the EVPN route updates that are involved in this example topology. As visible there are EVPN Type 2 MAC/IP routes, Type 3 IMET routes and Type 5 IP Prefix routes advertised between the PEs and the RR.
R8#show ip bgp l2vpn evpn all sum | beg Ne Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd 2.2.2.2 4 65100 143 172 20 0 0 02:00:12 4 « Four EVPN prefixes received on R8 from PE 6.6.6.6 4 65100 142 165 20 0 0 02:00:09 4 R8#show ip bgp l2vpn evpn all | beg Ne Network Next Hop Metric LocPrf Weight Path Route Distinguisher: 2.2.2.2:100 *>i [2][2.2.2.2:100][0][48][52540012ED6F][0][*]/20 « Route Type 2 2.2.2.2 0 100 0 ? Route Distinguisher: 6.6.6.6:100 *>i [2][6.6.6.6:100][0][48][52540004068C][0][*]/20 6.6.6.6 0 100 0 ? Route Distinguisher: 2.2.2.2:100 *>i [3][2.2.2.2:100][0][32][2.2.2.2]/17 « Route Type 3 2.2.2.2 0 100 0 ? Route Distinguisher: 6.6.6.6:100 *>i [3][6.6.6.6:100][0][32][6.6.6.6]/17 6.6.6.6 0 100 0 ? Route Distinguisher: 65100:1 *>i [5][65100:1][0][64][2001:DB8:A1::]/29 « Route Type 5 2.2.2.2 0 100 0 65001 i *>i [5][65100:1][0][64][2001:DB8:E1::]/29 2.2.2.2 0 100 0 i Route Distinguisher: 65100:2 *>i [5][65100:2][0][64][2001:DB8:A2::]/29 6.6.6.6 0 100 0 65002 i *>i [5][65100:2][0][64][2001:DB8:E2::]/29 6.6.6.6 0 100 0 i
Packet capture EVPN Route Type 5 with IPv6 prefix
The following packet capture shows an EVPN Type 5 IP Prefix Route advertised in a BGP Update message carrying the Site 2 IPv6 prefix. Note that a VPN service label (bottom label) is also attached to this route, enabling an end-to-end Label Switched Path (LSP) between the VRF Bridge Domain Interface (BDI) on each PE router. The bottom label ensures traffic finds the correct customer VRF when it reaches an egress PE router.