DMYTRO SHYTYI

ISIS Segment Routing IPv6 (SRv6) with FRR (FRRouting) and Ubuntu (WSL)

This post describes the ISIS Segment Routing IPv6 (SRv6) with FRR (FRRouting) and Ubuntu (WSL).

Code repositories

Credits:
Code authours: Carmine Scarpitta and Dmytro Shytyi.
[PART1] SRv6 multiple segs SIDs series of patches
[PART2] ISIS SRv6 series of patches

I would like to thank for a review: @cscarpitta @pushpasis @donaldsharp @routingrocks and @riw777.

Linux support

Ubuntu 22.04 within WSL was used for the testbed with kernel that has activated LW_TUNNELs (CONFIG_IPV6_SEG6_LWTUNNEL)

0root@munet:/# uname -a

1Linux munet 5.15.90.4-microsoft-standard-WSL2+ #1 SMP Fri Jul 28 00:56:47 CEST 2023 x86_64 x86_64 x86_64 GNU/Linux

Consider to activate Sysfs variable such as “Seg6 seg6_enabled” and/or “sysctl -w net.ipv6.conf.all.forwarding=1”.

FRR configuration

r1:

ipv6 route 2001:db8::/64 r1-r4 segs fc00:0:6::/fc00:0:5::/fc00:0:4::
!
interface lo
 ip address 1.1.1.1/32
 ip router isis 1
 ipv6 address fc00:0:1::1/128
 ipv6 router isis 1
 isis passive
exit
!
interface r1-r2
 ip address 10.0.1.1/24
 ip router isis 1
 ipv6 router isis 1
 isis hello-multiplier 3
exit
!
interface r1-r4
 ip address 10.0.4.1/24
 ip router isis 1
 ipv6 router isis 1
 isis hello-multiplier 3
exit
!
router isis 1
 is-type level-1
 net 49.0000.0000.0000.0001.00
 lsp-timers gen-interval 2 refresh-interval 900 max-lifetime 1200
 topology ipv6-unicast
 segment-routing srv6
 locator loc1
exit
!
segment-routing
 srv6
 locators
 locator loc1
 prefix fc00:0:1::/48 block-len 32 node-len 16 func-bits 16
 exit
 !
 exit
 !
 exit
 !
exit
!
end

r2:

interface lo
 ip address 2.2.2.2/32
 ip router isis 1
 ipv6 address fc00:0:2::1/128
 ipv6 router isis 1
 isis passive
exit
!
 interface r2-r1
 ip address 10.0.1.2/24
 ip router isis 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                
 ipv6 router isis 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                              
 isis hello-multiplier 3                                                                                                                                                                                                                                                                                                                                                                                                                                                                      exit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         !                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            interface r2-r3                                                                                                                                                                                                                                                                                                                                                                                                                                                                               ip address 10.0.2.2/24                                                                                                                                                                                                                                                                                                                                                                                                                                                                       ip router isis 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                             ipv6 router isis 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                           isis hello-multiplier 3                                                                                                                                                                                                                                                                                                                                                                                                                                                                     exit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         !                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            router isis 1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 is-type level-1                                                                                                                                                                                                                                                                                                                                                                                                                                                                              net 49.0000.0000.0000.0002.00                                                                                                                                                                                                                                                                                                                                                                                                                                                                lsp-timers gen-interval 2 refresh-interval 900 max-lifetime 1200                                                                                                                                                                                                                                                                                                                                                                                                                             topology ipv6-unicast                                                                                                                                                                                                                                                                                                                                                                                                                                                                        segment-routing srv6                                                                                                                                                                                                                                                                                                                                                                                                                                                                         locator loc1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                exit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         !                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            segment-routing                                                                                                                                                                                                                                                                                                                                                                                                                                                                               srv6                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         locators                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     locator loc1                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 prefix fc00:0:2::/48 block-len 32 node-len 16 func-bits 16                                                                                                                                                                                                                                                                                                                                                                                                                                   exit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         !                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            exit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         !                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            exit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         !                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           exit                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         !                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            end 

r7:

!
interface lo
 ip address 7.7.7.7/32
 ip router isis 1
 ipv6 address fc00:0:7::1/128
 ipv6 router isis 1
 isis passive
exit
!
interface r7-r3
 ip address 10.0.3.7/24
 ip router isis 1
 ipv6 router isis 1
 isis hello-multiplier 3
exit
!
interface r7-r6
 ip address 10.0.7.7/24
 ip router isis 1
 ipv6 router isis 1
 isis hello-multiplier 3
exit
!
router isis 1
 is-type level-1
 net 49.0000.0000.0000.0007.00
 lsp-timers gen-interval 2 refresh-interval 900 max-lifetime 1200
 topology ipv6-unicast
 segment-routing srv6
 locator loc1
exit
!
segment-routing
 srv6
 locators
 locator loc1
 prefix fc00:0:7::/48 block-len 32 node-len 16 func-bits 16
 exit
 !
 exit
 !
 exit
 !
exit
!
end

Display SRv6 route on r1

FRR:

r1# show ipv6 route
Codes: K - kernel route, C - connected, S - static, R - RIPng,
O - OSPFv3, I - IS-IS, B - BGP, T - Table, v - VNC,
V - VNC-Direct, A - Babel, F - PBR, f - OpenFabric,
> - selected route, * - FIB route, q - queued, r - rejected, b - backup
 t - trapped, o - offload failure

S>* 2001:db8::/64 [1/0] is directly connected, r1-r4, seg6 fc00:0:6::,fc00:0:5::,fc00:0:4::, weight 1, 01:52:08
[..]

iproute2:

root@r1:/# ip -6 route
2001:db8::/64 nhid 41 encap seg6 mode encap segs 3 [ fc00:0:4:: fc00:0:5:: fc00:0:6:: ] dev r1-r4 proto 196 metric 20 pref medium

Display ISIS SRv6 seg6local behavior on R2

The same seg6local behavior is bootstrapped on r3, r4, r5, r6, r7 nodes.

r2 router:

r2# show ipv6 route
Codes: K - kernel route, C - connected, S - static, R - RIPng,
 O - OSPFv3, I - IS-IS, B - BGP, T - Table, v - VNC,
 V - VNC-Direct, A - Babel, F - PBR, f - OpenFabric,
 > - selected route, * - FIB route, q - queued, r - rejected, b - backup
 t - trapped, o - offload failure
[..]
I>* fc00:0:2::/128 [115/0] is directly connected, sr0, seg6local End USP, weight 1, 02:34:25

r5 router:

r5# show ipv6 route
Codes: K - kernel route, C - connected, S - static, R - RIPng,
 O - OSPFv3, I - IS-IS, B - BGP, T - Table, v - VNC,
 V - VNC-Direct, A - Babel, F - PBR, f - OpenFabric,
 > - selected route, * - FIB route, q - queued, r - rejected, b - backup
 t - trapped, o - offload failure
​
[..]
I>* fc00:0:5::/128 [115/0] is directly connected, sr0, seg6local End USP, weight 1, 02:37:17

Testbed consoles presented with routers indexes

This figure is related to the network topology presented in the top of article. This figure describes router placement that doesn’t change in future figures.

Testbed – echo request/reply based on ISIS SPF (RED Line in the first figure)

This figure is related to the network topology presented in the top of article. This figure describes the echo “request”/”reply” process in regular setup. Echo request is sent via SPF (r1-r2-r3-r7) – red line in the first figure. Echo reply is returned in vise-versa manner.

Testbed – echo request/reply based with SRv6 features (Blue SRv6 Low-Latency tunnel)

This figure is related to the network topology presented in the top of article. This figure describes the echo “request”/”reply” process witch SRv6 features.
Echo request is sent via the low-latency path (r1-r4-r5-r6-r7) using the SRv6 route and returned by regular path (r7-r3-r2-r1).

Thank your for reading!