OcNOS-SP : Segment Routing Guide : Segment Routing Configuration Guide : TWAMP over EVPN-L3VPN with SR
TWAMP over EVPN-L3VPN with SR
TWAMP over EVPN L3VPN with SR feature brings together Two-way Active Measurement Protocol (TWAMP), Ethernet Virtual Private Network (EVPN) Layer 3 Virtual Private Network (L3VPN), and Segment Routing (SR) technologies. This integration revolutionizes the way network performance is monitored and managed.
This feature enables a comprehensive analysis of essential network performance metrics, including latency, packet loss, and various performance metrics.
.It provides information for optimizing network performance. With TWAMP over EVPN L3VPN with SR helps in troubleshooting issues, ensuring efficient resource utilization and reliable service delivery.
This solution is scalable, making it adaptable to a wide range of network configurations.
Topology
EVPN-L3VPN displays a sample TWAMP over EVPN-L3VPN topology.
CE1 and CE2 are customer edge routers
PE1 and PE2 are IPv4 Provider Edge routers
P1 is the router at the core of the IPv4 MPLS provider network.
TWAMP over EVPN-L3VPN Topology
SR-MPLS Configuration
PE1
SR-MPLS is configured on PE1 for IGP configs with ISIS and OSPF configuration
#configure terminal
Enter Configure mode.
(config)#int lo
Enter interface mode
(config-if)#ip add 1.1.1.1/32 secondary
Assign IP address to interface
(config-if)#prefix-sid index 100 no-php
Configure sid value with no-php
(config-if)#ip router isis 1
Make the interface part of the router ISIS 1 instance.
(config-if)#interface xe8
Enter Interface mode
(config-if)#load-interval 30
Enable load interval
(config-if)#ip address 10.1.1.1/30
Assign IP address to interface
(config-if)#mtu 9216
Set the mtu size
(config-if)#label-switching
Enable label switching.
(config-if)#ip ospf network point-to-point
Enable network as point to point
(config-if)#isis network point-to-point
Enable network as point to point
(config-if)#ip router isis 1
Make the interface part of the router ISIS 1 instance.
(config-router)#router isis 1
Set the routing process ID
(config-router)#is-type level-2-only
Configure isis level2
(config-router)#metric-style wide
Configure Network entity title (NET).
(config-router)#mpls traffic-eng router-id 1.1.1.1
Enable mpls traffic eng router-id
(config-router)#mpls traffic-eng level-2
Enable MPLS Traffic Engineering as level-2
(config-router)#capability cspf
Enable capability cspf
(config-router)#bfd all-interfaces
Enable bfd all interfaces
(config-router)#net 49.0001.0000.0001.0011.00
Configures a network with the address 49.0001.0000.0001.0011.00 in a router's configuration
(config-router)#isis segment-routing global block
Enable SRGB range under ISIS process
20000 23000
 
(config-router)#segment-routing mpls
Enable segment routing mpls ISIS process.
(config-router)#router ospf 1
Entering router ospf.
(config-router)#ospf router-id 1.1.1.1
Configure OSPF router-id.
(config-router)#bfd all-interfaces
Enable bfd all interfaces
(config-router)#network 1.1.1.1/32 area 0.0.0.0
Configures a network with the IP address 1.1.1.1 as a part of OSPF area 0.0.0.0 in a routers configuration.
(config-router)#network 10.1.1.0/24 area 0.0.0.0
Configures a network with the IP address 10.1.1.0 as a part of OSPF area 0.0.0.0 in a routers configuration.
 
(config-router)#ospf segment-routing global block
Enable SRGB range under OSPF process
16000 19000
 
(config-router)#segment-routing mpls
Enable segment routing mpls ISIS process.
(config-router)#commit
Commit the configurations
(config-router)#end
Return to privilege mode
P1
SR-MPLS is configured on P1 for IGP configs with ISIS and OSPF configuration.
 
#configure terminal
Enter Configure mode.
(config)#int lo
Enter interface mode
(config-if)#ip add 2.2.2.2/32 secondary
Assign IP address to interface
(config-if)#prefix-sid index 200 no-php
Configure sid value with no-php
(config-if)#ip router isis 1
Make the interface part of the router ISIS 1 instance.
(config-if)#interface xe8
Enter interface mode
(config-if)#load-interval 30
Enable load interval
(config-if)#ip address 10.1.1.2/30
Assign IP address to interface
(config-if)#mtu 9216
Set the mtu size
(config-if)#label-switching
Enable label switching.
(config-if)#ip ospf network point-to-point
Enable network as point to point
(config-if)#isis network point-to-point
Enable network as point to point
(config-if)#ip router isis 1
Make the interface part of the router ISIS 1 instance.
(config-if)#interface ce0
Enter interface mode
(config-if)#load-interval 30
Enable load interval
(config-if)#ip address 20.1.1.1/30
Assign IP address to interface
(config-if)#mtu 9216
Set the mtu size
(config-if)#label-switching
Enable label switching.
(config-if)#ip ospf network point-to-point
Enable network as point to point
(config-if)#isis network point-to-point
Enable network as point to point
(config-if)#ip router isis 1
Make the interface part of the router ISIS 1 instance.
(config-if)#router isis 1
Set the routing process ID
(config-router)#is-type level-2-only
Configure isis level2
(config-router)#metric-style wide
Configure Network entity title (NET).
(config-router)#mpls traffic-eng router-id 2.2.2.2
Enable mpls traffic eng router-id
(config-router)#mpls traffic-eng level-2
Enable MPLS Traffic Engineering as level-2
(config-router)#capability cspf
Enable capability cspf
(config-router)#bfd all-interfaces
Enable bfd all interfaces
(config-router)#net 49.0001.0000.0001.0022.00
Configure network.
(config-router)#isis segment-routing global block 20000 23000
Enable SRGB range under ISIS process
(config-router)#segment-routing mpls
Enable segment routing mpls ISIS process.
(config-router)#router ospf 1
Entering router ospf.
(config-router)#ospf router-id 2.2.2.2
Configure OSPF router-id.
(config-router)#bfd all-interfaces
Enable bfd all interfaces
(config-router)#network 2.2.2.2/32 area 0.0.0.0
Configures a network with the IP address 2.2.2.2 as a part of OSPF area 0.0.0.0 in a router's configuration
(config-router)#network 10.1.1.0/24 area 0.0.0.0
Configures a network with the IP address 10.1.1.0 as a part of OSPF area 0.0.0.0 in a router's configuration.
(config-router)#network 20.1.1.0/24 area 0.0.0.0
Configures a network with the IP address 20.1.1.0 as a part of OSPF area 0.0.0.0 in a router's configuration.
 
(config-router)#ospf segment-routing global block 16000 19000
Enable SRGB range under OSPF process
(config-router)#segment-routing mpls
Enable segment routing mpls ISIS process.
(config-router)#commit
Commit the configurations
(config-router)#end
Return to privilege mode
PE2
SR-MPLS is configured on PE2 for IGP configs with ISIS and OSPF configuration.
 
#configure terminal
Enter Configure mode.
(config)#int lo
Enter interface mode
(config-if)#ip add 3.3.3.3/32 secondary
Assign IP address to interface
(config-if)#prefix-sid index 300 no-php
Configure sid value with no-php
(config-if)#ip router isis 1
Make the interface part of the router ISIS 1 instance.
(config-if)#interface ce14
Enter interface mode
(config-if)#load-interval 30
Enable load interval
(config-if)#ip address 20.1.1.2/30
Assign IP address to interface
(config-if)#mtu 9216
Set the mtu size
(config-if)#label-switching
Enable label switching.
(config-if)#ip ospf network point-to-point
Enable network as point to point
(config-if)#isis network point-to-point
Enable network as point to point
(config-if)#ip router isis 1
Make the interface part of the router ISIS 1 instance.
(config-if)#route isis 1
Set the routing process ID
(config-router)#is-type level-2-only
Configure isis level2
(config-router)#metric-style wide
Configure Network entity title (NET).
(config-router)#mpls traffic-eng router-id 3.3.3.3
Enable mpls traffic eng router-id
(config-router)#mpls traffic-eng level-2
Enable MPLS Traffic Engineering as level-2
(config-router)#capability cspf
Enable capability cspf
(config-router)#bfd all-interfaces
Enable bfd all interfaces
(config-router)#net 49.0001.0000.0001.0033.00
Configure network.
(config-router)#isis segment-routing global block 20000 23000
Enable SRGB range under ISIS process
(config-router)#segment-routing mpls
Enable segment routing mpls ISIS process.
(config-router)#router ospf 1
Entering router ospf.
(config-router)#ospf router-id 3.3.3.3
Configure OSPF router-id.
(config-router)#bfd all-interfaces
Enable bfd all interfaces
(config-router)#network 3.3.3.3/32 area 0.0.0.0
Configure network.
(config-router)#network 20.1.1.0/24 area 0.0.0.0
Configure network.
(config-router)#ospf segment-routing global block 16000 19000
Enable SRGB range under OSPF process
(config-router)#segment-routing mpls
Enable segment routing mpls ISIS process.
(config-router)#commit
Commit the configurations
(config-router)#end
Return to privilege mode
Configure TWAMP over EVPN-L3VPN
PE1
 
#configure terminal
Enter Configure mode.
(config)# ip vrf vrf100
Create a new VRF named vrf100
(config-vrf)#rd 100:1
Assign the route distinguisher (RD) value as 100:1
(config-vrf)#route-target both 100:1
Import routes between route target (RT) ext-communities 100 and 1
(config)#l3vni 100
Configure L3vpn
(config-vrf)#exit
Exit VRF mode
(config)#int xe4
Enter Interface mode
(config-if)#mtu 9216
Set the mtu size
(config-if)#exit
Exit Interface mode
(config-if)#interface xe4.100
Enter Interface mode
(config-if)#encapsulation dot1q 100
Configure encapsulation under a subinterface
(config-if)#ip vrf forwarding vrf100
Bind the interface connected to the CE1 router with VRF 100
(config-if)#ip address 100.1.1.1/24
Assign IP address to interface
(config-if)#mtu 9216
Set the mtu size
(config-if)#exit
Exit
(config)#evpn mpls enable
Enable EVPN MPLS
(config)#evpn mpls irb
Enable EVPN IRB
(config)#evpn mpls vtep-ip-global 1.1.1.1
Configuring VTEP global IP to loopback IP
(config)#router bgp 65010
Enter BGP router mode
(config-router)#bgp router-id 1.1.1.1
Configure BGP router-id
(config-router)#neighbor 3.3.3.3 remote-as 65010
Configure PE2 as an iBGP4+ neighbor
(config-router)#neighbor 3.3.3.3 update-source lo
Update the source as loopback for iBGP peering with the remote PE2 router
(config-router)#address-family l2vpn evpn
address-family l2vpn evpn]
(config-router-af)#neighbor 3.3.3.3 activate
Activate the PE1 neighbor in the vpnv4 address family
(config-router-af)#exit-address-family
Exit
(config-router)#address-family ipv4 vrf vrf100
Enter the IPv4 address family for VRF 100
(config-router-af)#redistribute connected
Redistribute connected routes
(config-router-af)#neighbor 100.1.1.2 remote-as 100
Configure CE2 neighbor in the vrf address family
(config-router-af)#neighbor 100.1.1.2 activate
Activate the CE2 neighbor
(config-router-af)#exit-address-family
Exit form address family
(config-router)#commit
Commit the configurations
(config-router)#end
Return to privilege mode
 
 
PE2
 
#configure terminal
Enter Configure mode.
(config)#ip vrf vrf100
Create a new VRF named vrf100
(config-vrf)#rd 10:100
Assign the route distinguisher (RD) value as 10:100
(config-vrf)#route-target both 10:100
Import routes between route target (RT) ext-communities 10 and 100
(config-vrf)#l3vni 100
Configure L3vpn
(config-vrf)#int ce2
Enter Interface mode
(config-if)#mtu 9216
Set the mtu size
(config-if)#interface ce2.100
Enter Interface mode
(config-if)#encapsulation dot1q 100
Configure encapsulation under a subinterface
(config-if)#ip vrf forwarding vrf100
Bind the interface connected to the CE1 router with VRF 100
(config-if)#ip address 200.1.1.1/24
Assign IP address to interface
(config-if)#mtu 9216
Set the mtu size
(config-if)#evpn mpls enable
Enable EVPN MPLS
(config)#evpn mpls irb
Enable EVPN IRB
(config)#evpn mpls vtep-ip-global 3.3.3.3
Configuring VTEP global IP to loopback IP
(config)#router bgp 65010
Enter BGP router mode
(config-router)#bgp router-id 3.3.3.3
Configure BGP router-id
(config-router)#neighbor 1.1.1.1 update-source lo
Configure PE2 as an iBGP4+ neighbor
(config-router)#neighbor 1.1.1.1 remote-as 65010
Update the source as loopback for iBGP peering with the remote PE2 router
(config-router)#address-family l2vpn evpn
address-family l2vpn evpn
(config-router-af)#neighbor 1.1.1.1 activate
Activate the PE1 neighbor in the vpnv4 address family
(config-router-af)#exit-address-family
Exit
(config-router)#address-family ipv4 vrf vrf100
Enter the IPv4 address family for VRF 100
(config-router-af)#redistribute connected
Redistribute connected routes
(config-router-af)#neighbor 200.1.1.2 remote-as 200
Configure CE2 neighbor in the vrf address family
(config-router-af)#neighbor 200.1.1.2 activate
Activate the CE2 neighbor
(config-router-af)#exit-address-family
Exit form address family
(config-router)#commit
Commit the configurations
(config-router)#end
Return to privilege mode
 
CE1
 
#configure terminal
Enter Configure mode.
(config)#int xe4
Enter Interface mode
(config-if)#mtu 9216
Set the mtu size
(config-if)#interface xe4.100
Enter Interface mode
(config-if)#encapsulation dot1q 100
Configure encapsulation under a subinterface
(config-if)#load-interval 30
Enable load interval
(config-if)#ip address 100.1.1.2/24
Assign IP address to interface
(config-if)#mtu 9216
Set the mtu size
(config-if)#interface lo
Configure lo interface
(config-if)#ip address 11.11.11.11/32 secondary
Assign IP address to interface
(config-if)#router bgp 100
Enter BGP router mode
(config-router-af)#neighbor 100.1.1.1 remote-as 65010
Configure BGP router-id
(config-router-af)#address-family ipv4 unicast
Enter address-family vpnv4 mode
(config-router-af)#neighbor 100.1.1.1 activate
mode Activate VPNv4 neighbor
(config-router-af)#redistribute connected
Redistribute connected routes
(config-router-af)#commit
Commit the configurations
(config-router-af)#end
Return to privilege mode
 
CE2
 
#configure terminal
Enter Configure mode.
(config)#int ce0
Enter Interface mode
(config)#mtu 9216
Set the mtu size
(config)#interface ce0.100
Enter Interface mode
(config)#encapsulation dot1q 100
Configure encapsulation under a subinterface
(config)#load-interval 30
Enable load interval
(config)#ip address 200.1.1.2/24
Assign IP address to interface
(config)#mtu 9216
Set the mtu size
(config-if)#interface lo
Configure lo interface
(config-if)#ip address 22.22.22.22/32 secondary
Assign IP address to interface
(config)#router bgp 200
Enter BGP router mode
(config)#neighbor 200.1.1.1 remote-as 65010
Configure BGP router-id
(config)#address-family ipv4 unicast
Enter address-family vpnv4 mode
(config)#neighbor 200.1.1.1 activate
mode Activate VPNv4 neighbor
(config)#redistribute connected
Redistribute connected routes
(config)#commit
Commit the configurations
(config)#end
Return to privilege mode
TWAMP Configuration on Sender (CE1)
TWAMP sender is configured to measure the delay on interface Loopback on CE1
 
#configure terminal
Enter Configure mode.
(config)# hardware-profile filter twamp-ipv4 enable
Enable hardware filter for ipv4 to configure TWAMP meas- urement configs
(config)#commit
Commit the configuration
(config)# twamp-light control
Enable TWAMP light controller on PE1
(config-twamp-light-ctrl)# control-admin- state enable
Enable TWAMP Controller admin state
(config-twamp-light-ctrl)#delay-profile interfaces
Enter in to delay profile mode
(config-dp-intf)#mode two-way
Enter mode
(config-dp-intf)#burst-count 1
Enter burst count
(config-dp-intf)#burst-interval 1000
Configure burst interval value under delay profile mode
(config-dp-intf)#interval 30
Configure interval
(config-dp-intf)#advertisement periodic threshold 10
Configure advertisement periodic
(config-dp-intf)#advertisement periodic minimum-change 1000
Configure advertisement periodic
(config-dp-intf)#advertisement accelerated
Configure advertisement accelerated
(config-dp-intf)#advertisement accelerated threshold 20
Configure advertisement accelerated threshold
(config-dp-intf)#advertisement accelerated minimum-change 2000
Configure advertisement accelerated
(config-dp-intf)#int lo
Enter Interface Loopback mode
(config-if)#loss-measurement dynamic
Configure loss measurement
(config-if)#delay-measurement dynamic twamp reflector-ip 22.22.22.22 sender-ip 11.11.11.11
Enter in to delay profile mode
(config-if)#commit
Commit the configurations
(config-if)#end
Return to privilege mode
TWAMP Configuration on Reflector (CE2)
Configure TWAMP Reflector as interface xe24 on CE2 (Towards core)
 
#configure terminal
Enter Configure mode.
(config)# hardware-profile filter twamp-ipv4 enable
Enable hardware filter for ipv4 to configure TWAMP meas- urement configs
(config)#commit
Commit the configuration
(config)# twamp-light reflector
Enable TWAMP light Reflector on PE2
(config-twamp-light-ref)# reflec-tor-admin- state enable
Enable the TWAMP reflector admin state
(config-twamp-light-ref)# reflector-name CE2-CE1-lo reflector-ip ipv4 22.22.22.22
Configure TWAMP reflector IP as PE2 interface IP
(config-twamp-light-ref)#commit
Commit the configurations
(config-if)#end
Return to privilege mode
Validation
EVPN-L3VPN over SR VALIDATION
Verify mpls EVPN-L3VPN ping from PE1
PE1#sh evpn mpls status
EVPN-MPLS is ACTIVE in Hardware
Verify show evpn mpls tunnel from PE1
PE1#show evpn mpls tunnel
EVPN-MPLS Network tunnel Entries
Source Destination Status Up/Down Update evpn
-id
================================================================================
===
1.1.1.1 3.3.3.3 Installed 02:50:36 02:50:36 100
Total number of entries are 1
Verify show evpn mpls id 100
EVPN-MPLS Information
=================
Codes: NW - Network Port
AC - Access Port
(u) - Untagged
VPN-ID EVI-Name EVI-Type Type Interface ESI VLAN
DF-Status Src-Addr Dst-Addr
________________________________________________________________________________
_______________________________________________
100 ---- L3 NW ---- ---- ----
---- 1.1.1.1 3.3.3.3
Total number of entries are 1
Verify show mpls vrf-forwarding table
PE1#sh mpls vrf-forwarding-table
Codes: > - installed FTN, * - selected FTN, p - stale FTN, B - BGP FTN
(m) - Service mapped over multipath transport
Code FEC FTN-ID Tunnel-id Pri LSP-Type Out-Label
Out-Intf Nexthop
B> 22.22.22.22/32 2 0 Yes LSP_DEFAULT 16
- 3.3.3.3
B> 200.1.1.0/24 1 0 Yes LSP_DEFAULT 16
- 3.3.3.3
Verify mpls l3vpn ping
PE1#ping mpls l3vpn vrf100 200.1.1.0/24 detail
Sending 5 MPLS Echos to 200.1.1.0, timeout is 5 seconds
Codes:
'!' - Success, 'Q' - request not sent, '.' - timeout,
'x' - Retcode 0, 'M' - Malformed Request, 'm' - Errored TLV,
'N' - LBL Mapping Err, 'D' - DS Mismatch,
'U' - Unknown Interface, 'R' - Transit (LBL Switched),
'B' - IP Forwarded, 'F' No FEC Found, 'f' - FEC Mismatch,
'P' - Protocol Error, 'X' - Unknown code,
'Z' - Reverse FEC Validation Failed
 
Type 'Ctrl+C' to abort
 
! seq_num = 1 20.1.1.2 0.82 ms
! seq_num = 2 20.1.1.2 0.57 ms
! seq_num = 3 20.1.1.2 0.52 ms
! seq_num = 4 20.1.1.2 0.57 ms
! seq_num = 5 20.1.1.2 0.53 ms
 
Success Rate is 100.00 percent (5/5)
round-trip min/avg/max = 0.52/0.67/0.82
 
PE1#ping mpls l3vpn vrf100 22.22.22.22/32 detail
Sending 5 MPLS Echos to 22.22.22.22, timeout is 5 seconds
 
Codes:
'!' - Success, 'Q' - request not sent, '.' - timeout,
'x' - Retcode 0, 'M' - Malformed Request, 'm' - Errored TLV,
'N' - LBL Mapping Err, 'D' - DS Mismatch,
'U' - Unknown Interface, 'R' - Transit (LBL Switched),
'B' - IP Forwarded, 'F' No FEC Found, 'f' - FEC Mismatch,
'P' - Protocol Error, 'X' - Unknown code,
'Z' - Reverse FEC Validation Failed
 
Type 'Ctrl+C' to abort
 
! seq_num = 1 20.1.1.2 0.75 ms
! seq_num = 2 20.1.1.2 0.61 ms
! seq_num = 3 20.1.1.2 0.59 ms
! seq_num = 4 20.1.1.2 0.66 ms
! seq_num = 5 20.1.1.2 0.67 ms
 
Success Rate is 100.00 percent (5/5)
round-trip min/avg/max = 0.59/0.67/0.75
TWAMP VALIDATION
ping between CE1 lo to CE2 lo
CE1#ping 22.22.22.22
Press CTRL+C to exit
PING 22.22.22.22 (22.22.22.22) 56(84) bytes of data.
64 bytes from 22.22.22.22: icmp_seq=1 ttl=62 time=0.564 ms
64 bytes from 22.22.22.22: icmp_seq=2 ttl=62 time=0.426 ms
64 bytes from 22.22.22.22: icmp_seq=3 ttl=62 time=0.848 ms
 
--- 22.22.22.22 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 61ms
rtt min/avg/max/mdev = 0.426/0.612/0.848/0.177 ms
 
Verify the TWAMP statistics on all the configured interfaces on CE1.In the below verification command, packets sent and received showing as equal. So all the TWAMP packets received reply for all the sent packets for the delay measurement. Showing all the Round Trip Delay and Reverse Delay timers.
CE1#show twamp-statistics
=========================================
TWAMP Test-Session Statistics
=========================================
Test-Session Name : __internal_interface_lo
Start Time : 2023 Oct 16 22:59:07
Elapsed time(milli sec) : 16008
Packets Sent : 16
Packets Received : 16
Packet Loss(%) : 0.00
Round Trip Delay(usec)
Minimum : 277
Maximum : 595
Average : 387
Forward Delay(usec)
Minimum : (*)
Maximum : (*)
Average : (*)
Reverse Delay(usec)
Minimum : (*)
Maximum : (*)
Average : (*)
Round Trip Delay Variation(usec)
Minimum : 220
Maximum : 406
Average : 300
Forward Delay Variation(usec)
Minimum : (*)
Maximum : (*)
Average : (*)
Reverse Delay Variation(usec)
Minimum : (*)
Maximum : (*)
Average : (*)
 
(*) - Time is not in sync between Sender and Reflector
 
sh twamp-statistics interfaces
CE1#sh twamp-statistics interfaces
Interface Last Advertisement Delay(us) Min(us) Max(us) Var(us) Loss(%)
lo 2023-10-16 23:00:52 148 148 148 0 0.00
 
Verify the Detailed list of TWAMP delay measurement information on CE lo interface
CE1#sh twamp-statistics interfaces lo
Interface name : lo
Sender IP : 11.11.11.11
Reflector IP : 22.22.22.22
Reflector port : 862
DSCP value : 0
HW Status : -
Last Advertised stats:
Time: 2023-10-16 23:01:12
Average delay : 145
Minimum delay : 106
Maximum delay : 165
Average delay variation: 3
Minimum delay variation: 2
Maximum delay variation: 6
Packets sent : 13
Packets received : 13
Packets timeout : 0
Packet Loss: 0.00
Last Calculated stats:
Time: 2023-10-16 23:01:12
Average delay : 145
Minimum delay : 106
Maximum delay : 165
Average delay variation: 3
Minimum delay variation: 2
Maximum delay variation: 6
Packets sent : 13
Packets received : 13
Packets timeout : 0
Packet Loss : 0.00