SlideShare a Scribd company logo
1 of 27
Implementing IPv6 Segment
Routing in the Linux Kernel
David Lebrun, Olivier Bonaventure
ICTEAM, UCLouvain, Belgium
Work supported by ARC grant 12/18-054 (ARC-SDN) and a Cisco grant
Agenda
• IPv6 Segment Routing
• Implementation in the Linux kernel
• Performance evaluation
Packet along
shortest path to R5
What is Segment Routing ?
• The return of Source Routing
– Each packet contains a loose route to encode any
path inside the network
R1
R2
R3 R5
R7
R6
R5->R2->R6
Packet along
shortest path to R2
R5->R2->R6
Normal IPv6
forwarding
Normal IPv6
forwarding
R2->R6
->R6
Packet along
shortest path to R6
->R6
IPv6 Segment Routing
• Basic principles
– IGP distributes IPv6 prefixes and router loopback
addresses
– Loose source route encoded inside IPv6 extension
header containing a list of segments
– Main types of segments
• Node segment (router's loopback address)
• Adjacency segment (router outgoing interface)
• Virtual function (operator defined function)
https://tools.ietf.org/html/draft-ietf-6man-segment-routing-header-06
http://www.segment-routing.net
The IPv6 Segment Routing Header
Remaining
segments
Each segment is
one IPv6 address
Index of last
segment
Extensibility
IPv6 Segment Routing use cases
• Paths controlled by the endhosts
R1
R2
R3 R5
R7
R6
R5->R2->R6->D
R5->R2->R6->D
R5->R2->R6->D
R5->R5->R6->D
R5->R2->R6->D
R5->R2->R6->D
R5->R2->R6->D
Source adds SRH to
all packets
Destination
removes SRH from
all packets
Network Function Virtualisation
• Force packets to pass through NFV
R1
R2
R3 R5
R7
R6
R5->FCT->R6
R5->FCT->D
R5->FCT->R6
R5->FCT->D
FCT performed
on R5
R5->FCT->D
FCT
Encap and decap
• Routers can also tunnel SRH packets
R1
R2
R3 R5
R7
R6
->D
R1->R5->R7->R6 [->D]
->D
Ingress router
encaps to R6
with SRH
R1->R5->R7->R6 [->D]
Egress router
decaps and
removes SRH
R1->R5->R7->R6 [->D]
R1->R5->R7->R6 [->D]
R1->R5->R7->R6 [->D]
Security: Learning from the past
• How to avoid past failures of source routing ?
The IPv6 SRH HMAC TLV
Different keys and
different hash
functions can be used
Utilisation of the HMAC TLV
• All routers are configured with an HMAC key
• Clients receive SRH with HMAC key
– E.g. from SDN controlled
• Trusted servers configured with HMAC key
R1
R2
R3 R5
R7
R6
Agenda
• IPv6 Segment Routing
• Implementation in the Linux kernel
• Performance evaluation
Basics of Linux packet processing
Packet recvd
for local
process
Packet sent
by local
process
Forwarded packet
Packet forwarding with IPv6 SR
• Router is one of the segments in the list
SRH updated,
Packet
forwarded to
next segment
Packet forwarding with IPv6 SR
• Egress router receiving encapsulated packet
SRH
processed
encapsulation
removed
How to configure IPv6 SR ?
• IPv6 SR implementation extends iproute2
– Commands passed through rtnetlink
– Example
ip −6 route add fc42::/64
encap seg6 mode encap
segs fc00::1,2001:db8::1,fc10::7
dev eth0
Destination match
SRv6 encap
Segments added in
the encapsulated
packet
SRH usage by applications
• Endhosts can control the SRH on a per flow
basis through the socket API
HMAC processing
• Three modes of operations can be configured
– Ignore
• All packets are forwarded independently of the HMACs
– Verify
• Packets containing an HMAC are processed if HMAC is
valid
• Packets without HMAC are processed
– Enforce
• Packets containing an HMAC are processed if HMAC is
valid
• Packets without HMAC are discarded
Agenda
• IPv6 Segment Routing
• Implementation in the Linux kernel
• Performance evaluation
Lab measurements
• Lab setup
– Intel Xeon X3440 processors (4 cores 8 threads at 2.53 GHz
– 16 GB of RAM
– two Intel 82599 10 Gbps Ethernet
• One queue per CPU, one IRQ per queue
– Linux kernel 4.11-rc3, TSO and GRO disabled
• Traffic generator
– Pktgen, in-kernel module sending UDP packets
10 Gbps Ethernet 10 Gbps Ethernet
First measurements with one CPU
Why this gap ?
Baseline
Plain IPv6
forwarding
No difference between
SRH forwarding and
encap+forwarding
Performance limitations
of the first implementation
• Route lookup
– Destination cache was implemented for locally
generated packets but not forwarded ones
• Fixed with a dest cache
• Issue with memory allocation
– Forced free to take a slow path involving spinlocks
in case packet was processed by different CPU
than NIC IRQ
• Fixed with a better utilisation of the skb
Improved performance on one CPU
IPv6 SRH forwarding and encap
are now close to plain IPv6
packet fowarding performance
Does packet size affect performance ?
1000 bytes 1000 bytes
64 64
Cost of HMAC
Pure C code
Special intel
instructions
Leveraging multiple cores
Performance
scales well with
the number of
physical CPUS
Conclusion
• IPv6 Segment Routing has matured
– Stable specification
– Various use cases
• Implementation in the Linux kernel 4.11+
– Endhost functions for clients and servers
– Router functions
• Performance evaluation
– Good forwarding and encap/decap performance
– Unsurprisingly HMAC TLV affects performance
http://www.segment-routing.org

More Related Content

What's hot

EBPF and Linux Networking
EBPF and Linux NetworkingEBPF and Linux Networking
EBPF and Linux NetworkingPLUMgrid
 
How to Survive an OpenStack Cloud Meltdown with Ceph
How to Survive an OpenStack Cloud Meltdown with CephHow to Survive an OpenStack Cloud Meltdown with Ceph
How to Survive an OpenStack Cloud Meltdown with CephSean Cohen
 
BPF - in-kernel virtual machine
BPF - in-kernel virtual machineBPF - in-kernel virtual machine
BPF - in-kernel virtual machineAlexei Starovoitov
 
Deploying CloudStack and Ceph with flexible VXLAN and BGP networking
Deploying CloudStack and Ceph with flexible VXLAN and BGP networking Deploying CloudStack and Ceph with flexible VXLAN and BGP networking
Deploying CloudStack and Ceph with flexible VXLAN and BGP networking ShapeBlue
 
Pushing Packets - How do the ML2 Mechanism Drivers Stack Up
Pushing Packets - How do the ML2 Mechanism Drivers Stack UpPushing Packets - How do the ML2 Mechanism Drivers Stack Up
Pushing Packets - How do the ML2 Mechanism Drivers Stack UpJames Denton
 
Boosting I/O Performance with KVM io_uring
Boosting I/O Performance with KVM io_uringBoosting I/O Performance with KVM io_uring
Boosting I/O Performance with KVM io_uringShapeBlue
 
LinuxCon 2015 Linux Kernel Networking Walkthrough
LinuxCon 2015 Linux Kernel Networking WalkthroughLinuxCon 2015 Linux Kernel Networking Walkthrough
LinuxCon 2015 Linux Kernel Networking WalkthroughThomas Graf
 
Java Performance Analysis on Linux with Flame Graphs
Java Performance Analysis on Linux with Flame GraphsJava Performance Analysis on Linux with Flame Graphs
Java Performance Analysis on Linux with Flame GraphsBrendan Gregg
 
How VXLAN works on Linux
How VXLAN works on LinuxHow VXLAN works on Linux
How VXLAN works on LinuxEtsuji Nakai
 
Vxlan deep dive session rev0.5 final
Vxlan deep dive session rev0.5   finalVxlan deep dive session rev0.5   final
Vxlan deep dive session rev0.5 finalKwonSun Bae
 
Using ScyllaDB for Distribution of Game Assets in Unreal Engine
Using ScyllaDB for Distribution of Game Assets in Unreal EngineUsing ScyllaDB for Distribution of Game Assets in Unreal Engine
Using ScyllaDB for Distribution of Game Assets in Unreal EngineScyllaDB
 
Kvm performance optimization for ubuntu
Kvm performance optimization for ubuntuKvm performance optimization for ubuntu
Kvm performance optimization for ubuntuSim Janghoon
 
eBPF - Rethinking the Linux Kernel
eBPF - Rethinking the Linux KerneleBPF - Rethinking the Linux Kernel
eBPF - Rethinking the Linux KernelThomas Graf
 
Linux Linux Traffic Control
Linux Linux Traffic ControlLinux Linux Traffic Control
Linux Linux Traffic ControlSUSE Labs Taipei
 
Cumulus networks conversion guide
Cumulus networks conversion guideCumulus networks conversion guide
Cumulus networks conversion guideScott Suehle
 
LISA2019 Linux Systems Performance
LISA2019 Linux Systems PerformanceLISA2019 Linux Systems Performance
LISA2019 Linux Systems PerformanceBrendan Gregg
 
2014 OpenStack Summit - Neutron OVS to LinuxBridge Migration
2014 OpenStack Summit - Neutron OVS to LinuxBridge Migration2014 OpenStack Summit - Neutron OVS to LinuxBridge Migration
2014 OpenStack Summit - Neutron OVS to LinuxBridge MigrationJames Denton
 
eBPF Trace from Kernel to Userspace
eBPF Trace from Kernel to UserspaceeBPF Trace from Kernel to Userspace
eBPF Trace from Kernel to UserspaceSUSE Labs Taipei
 

What's hot (20)

EBPF and Linux Networking
EBPF and Linux NetworkingEBPF and Linux Networking
EBPF and Linux Networking
 
How to Survive an OpenStack Cloud Meltdown with Ceph
How to Survive an OpenStack Cloud Meltdown with CephHow to Survive an OpenStack Cloud Meltdown with Ceph
How to Survive an OpenStack Cloud Meltdown with Ceph
 
BPF - in-kernel virtual machine
BPF - in-kernel virtual machineBPF - in-kernel virtual machine
BPF - in-kernel virtual machine
 
Deploying CloudStack and Ceph with flexible VXLAN and BGP networking
Deploying CloudStack and Ceph with flexible VXLAN and BGP networking Deploying CloudStack and Ceph with flexible VXLAN and BGP networking
Deploying CloudStack and Ceph with flexible VXLAN and BGP networking
 
Pushing Packets - How do the ML2 Mechanism Drivers Stack Up
Pushing Packets - How do the ML2 Mechanism Drivers Stack UpPushing Packets - How do the ML2 Mechanism Drivers Stack Up
Pushing Packets - How do the ML2 Mechanism Drivers Stack Up
 
Boosting I/O Performance with KVM io_uring
Boosting I/O Performance with KVM io_uringBoosting I/O Performance with KVM io_uring
Boosting I/O Performance with KVM io_uring
 
LinuxCon 2015 Linux Kernel Networking Walkthrough
LinuxCon 2015 Linux Kernel Networking WalkthroughLinuxCon 2015 Linux Kernel Networking Walkthrough
LinuxCon 2015 Linux Kernel Networking Walkthrough
 
Java Performance Analysis on Linux with Flame Graphs
Java Performance Analysis on Linux with Flame GraphsJava Performance Analysis on Linux with Flame Graphs
Java Performance Analysis on Linux with Flame Graphs
 
How VXLAN works on Linux
How VXLAN works on LinuxHow VXLAN works on Linux
How VXLAN works on Linux
 
Vxlan deep dive session rev0.5 final
Vxlan deep dive session rev0.5   finalVxlan deep dive session rev0.5   final
Vxlan deep dive session rev0.5 final
 
Using ScyllaDB for Distribution of Game Assets in Unreal Engine
Using ScyllaDB for Distribution of Game Assets in Unreal EngineUsing ScyllaDB for Distribution of Game Assets in Unreal Engine
Using ScyllaDB for Distribution of Game Assets in Unreal Engine
 
OpenStack HA
OpenStack HAOpenStack HA
OpenStack HA
 
Neutron qos overview
Neutron qos overviewNeutron qos overview
Neutron qos overview
 
Kvm performance optimization for ubuntu
Kvm performance optimization for ubuntuKvm performance optimization for ubuntu
Kvm performance optimization for ubuntu
 
eBPF - Rethinking the Linux Kernel
eBPF - Rethinking the Linux KerneleBPF - Rethinking the Linux Kernel
eBPF - Rethinking the Linux Kernel
 
Linux Linux Traffic Control
Linux Linux Traffic ControlLinux Linux Traffic Control
Linux Linux Traffic Control
 
Cumulus networks conversion guide
Cumulus networks conversion guideCumulus networks conversion guide
Cumulus networks conversion guide
 
LISA2019 Linux Systems Performance
LISA2019 Linux Systems PerformanceLISA2019 Linux Systems Performance
LISA2019 Linux Systems Performance
 
2014 OpenStack Summit - Neutron OVS to LinuxBridge Migration
2014 OpenStack Summit - Neutron OVS to LinuxBridge Migration2014 OpenStack Summit - Neutron OVS to LinuxBridge Migration
2014 OpenStack Summit - Neutron OVS to LinuxBridge Migration
 
eBPF Trace from Kernel to Userspace
eBPF Trace from Kernel to UserspaceeBPF Trace from Kernel to Userspace
eBPF Trace from Kernel to Userspace
 

Viewers also liked

Some lessons learned developing OERs over a decade
Some lessons learned developing OERs over a decadeSome lessons learned developing OERs over a decade
Some lessons learned developing OERs over a decadeOlivier Bonaventure
 
Internet innovation with Multipath TCP
Internet innovation with Multipath TCPInternet innovation with Multipath TCP
Internet innovation with Multipath TCPOlivier Bonaventure
 
Beyond TCP: The evolution of Internet transport protocols
Beyond TCP: The evolution of Internet transport protocolsBeyond TCP: The evolution of Internet transport protocols
Beyond TCP: The evolution of Internet transport protocolsOlivier Bonaventure
 
Beyond TCP: The evolution of Internet transport protocols
Beyond TCP: The evolution of Internet transport protocolsBeyond TCP: The evolution of Internet transport protocols
Beyond TCP: The evolution of Internet transport protocolsOlivier Bonaventure
 
Computer Networking : Principles, Protocols and Practice - lesson 1
Computer Networking : Principles, Protocols and Practice - lesson 1Computer Networking : Principles, Protocols and Practice - lesson 1
Computer Networking : Principles, Protocols and Practice - lesson 1Olivier Bonaventure
 

Viewers also liked (9)

12 ethernet-wifi
12 ethernet-wifi12 ethernet-wifi
12 ethernet-wifi
 
Some lessons learned developing OERs over a decade
Some lessons learned developing OERs over a decadeSome lessons learned developing OERs over a decade
Some lessons learned developing OERs over a decade
 
Internet innovation with Multipath TCP
Internet innovation with Multipath TCPInternet innovation with Multipath TCP
Internet innovation with Multipath TCP
 
Beyond TCP: The evolution of Internet transport protocols
Beyond TCP: The evolution of Internet transport protocolsBeyond TCP: The evolution of Internet transport protocols
Beyond TCP: The evolution of Internet transport protocols
 
Beyond TCP: The evolution of Internet transport protocols
Beyond TCP: The evolution of Internet transport protocolsBeyond TCP: The evolution of Internet transport protocols
Beyond TCP: The evolution of Internet transport protocols
 
9 ipv6-routing
9 ipv6-routing9 ipv6-routing
9 ipv6-routing
 
6 app-tcp
6 app-tcp6 app-tcp
6 app-tcp
 
Computer Networking : Principles, Protocols and Practice - lesson 1
Computer Networking : Principles, Protocols and Practice - lesson 1Computer Networking : Principles, Protocols and Practice - lesson 1
Computer Networking : Principles, Protocols and Practice - lesson 1
 
10 routing-bgp
10 routing-bgp10 routing-bgp
10 routing-bgp
 

Similar to Implementing IPv6 Segment Routing in the Linux kernel

IPv6 Segment Routing : an end-to-end solution ?
IPv6 Segment Routing : an end-to-end solution ?IPv6 Segment Routing : an end-to-end solution ?
IPv6 Segment Routing : an end-to-end solution ?Olivier Bonaventure
 
IPv4aaS tutorial and hands-on
IPv4aaS tutorial and hands-onIPv4aaS tutorial and hands-on
IPv4aaS tutorial and hands-onAPNIC
 
Tutorial: IPv6-only transition with demo
Tutorial: IPv6-only transition with demoTutorial: IPv6-only transition with demo
Tutorial: IPv6-only transition with demoAPNIC
 
Fastsocket Linxiaofeng
Fastsocket LinxiaofengFastsocket Linxiaofeng
Fastsocket LinxiaofengMichael Zhang
 
IPv6 Transition & Deployment, including IPv6-only in cellular and broadband
IPv6 Transition & Deployment, including IPv6-only in cellular and broadbandIPv6 Transition & Deployment, including IPv6-only in cellular and broadband
IPv6 Transition & Deployment, including IPv6-only in cellular and broadbandAPNIC
 
Day5_Lab_9_Introduction_to_Segment_Routing_over_IPv6_SRv6.pdf
Day5_Lab_9_Introduction_to_Segment_Routing_over_IPv6_SRv6.pdfDay5_Lab_9_Introduction_to_Segment_Routing_over_IPv6_SRv6.pdf
Day5_Lab_9_Introduction_to_Segment_Routing_over_IPv6_SRv6.pdfHebaalrahmanAzletine
 
Segment Routing v6 (SRv6) Academy Update
Segment Routing v6 (SRv6) Academy Update Segment Routing v6 (SRv6) Academy Update
Segment Routing v6 (SRv6) Academy Update Chunghan Lee
 
Router configuration
Router configurationRouter configuration
Router configuration97148881557
 
TechWiseTV Workshop: Segment Routing for the Datacenter
TechWiseTV Workshop: Segment Routing for the DatacenterTechWiseTV Workshop: Segment Routing for the Datacenter
TechWiseTV Workshop: Segment Routing for the DatacenterRobb Boyd
 
Multiprotocol label switching (mpls) - Networkshop44
Multiprotocol label switching (mpls)  - Networkshop44Multiprotocol label switching (mpls)  - Networkshop44
Multiprotocol label switching (mpls) - Networkshop44Jisc
 
Evolution Network
Evolution NetworkEvolution Network
Evolution NetworkAPNIC
 
Ocpeu14
Ocpeu14Ocpeu14
Ocpeu14KALRAY
 
FD.io Vector Packet Processing (VPP)
FD.io Vector Packet Processing (VPP)FD.io Vector Packet Processing (VPP)
FD.io Vector Packet Processing (VPP)Kirill Tsym
 

Similar to Implementing IPv6 Segment Routing in the Linux kernel (20)

IPv6 Segment Routing : an end-to-end solution ?
IPv6 Segment Routing : an end-to-end solution ?IPv6 Segment Routing : an end-to-end solution ?
IPv6 Segment Routing : an end-to-end solution ?
 
IPv4aaS tutorial and hands-on
IPv4aaS tutorial and hands-onIPv4aaS tutorial and hands-on
IPv4aaS tutorial and hands-on
 
Tutorial: IPv6-only transition with demo
Tutorial: IPv6-only transition with demoTutorial: IPv6-only transition with demo
Tutorial: IPv6-only transition with demo
 
Fastsocket Linxiaofeng
Fastsocket LinxiaofengFastsocket Linxiaofeng
Fastsocket Linxiaofeng
 
IPv6 transition and coexistance - Jordi Palet
IPv6 transition and coexistance - Jordi PaletIPv6 transition and coexistance - Jordi Palet
IPv6 transition and coexistance - Jordi Palet
 
IPv6 Transition & Deployment, including IPv6-only in cellular and broadband
IPv6 Transition & Deployment, including IPv6-only in cellular and broadbandIPv6 Transition & Deployment, including IPv6-only in cellular and broadband
IPv6 Transition & Deployment, including IPv6-only in cellular and broadband
 
Run Your Own 6LoWPAN Based IoT Network
Run Your Own 6LoWPAN Based IoT NetworkRun Your Own 6LoWPAN Based IoT Network
Run Your Own 6LoWPAN Based IoT Network
 
pps Matters
pps Matterspps Matters
pps Matters
 
Day5_Lab_9_Introduction_to_Segment_Routing_over_IPv6_SRv6.pdf
Day5_Lab_9_Introduction_to_Segment_Routing_over_IPv6_SRv6.pdfDay5_Lab_9_Introduction_to_Segment_Routing_over_IPv6_SRv6.pdf
Day5_Lab_9_Introduction_to_Segment_Routing_over_IPv6_SRv6.pdf
 
Segment Routing v6 (SRv6) Academy Update
Segment Routing v6 (SRv6) Academy Update Segment Routing v6 (SRv6) Academy Update
Segment Routing v6 (SRv6) Academy Update
 
Router configuration
Router configurationRouter configuration
Router configuration
 
TechWiseTV Workshop: Segment Routing for the Datacenter
TechWiseTV Workshop: Segment Routing for the DatacenterTechWiseTV Workshop: Segment Routing for the Datacenter
TechWiseTV Workshop: Segment Routing for the Datacenter
 
Router configuration
Router configurationRouter configuration
Router configuration
 
EIGRP, DHCP, OSPF, NAT
EIGRP, DHCP, OSPF, NATEIGRP, DHCP, OSPF, NAT
EIGRP, DHCP, OSPF, NAT
 
Multiprotocol label switching (mpls) - Networkshop44
Multiprotocol label switching (mpls)  - Networkshop44Multiprotocol label switching (mpls)  - Networkshop44
Multiprotocol label switching (mpls) - Networkshop44
 
Ipv6
Ipv6Ipv6
Ipv6
 
Evolution Network
Evolution NetworkEvolution Network
Evolution Network
 
Ocpeu14
Ocpeu14Ocpeu14
Ocpeu14
 
Routing protocols
Routing protocolsRouting protocols
Routing protocols
 
FD.io Vector Packet Processing (VPP)
FD.io Vector Packet Processing (VPP)FD.io Vector Packet Processing (VPP)
FD.io Vector Packet Processing (VPP)
 

More from Olivier Bonaventure

A personal journey towards more reproducible networking research
A personal journey towards more reproducible networking researchA personal journey towards more reproducible networking research
A personal journey towards more reproducible networking researchOlivier Bonaventure
 
Part 11 : Interdomain routing with BGP
Part 11 : Interdomain routing with BGPPart 11 : Interdomain routing with BGP
Part 11 : Interdomain routing with BGPOlivier Bonaventure
 
Part 10 : Routing in IP networks and interdomain routing with BGP
Part 10 : Routing in IP networks and interdomain routing with BGPPart 10 : Routing in IP networks and interdomain routing with BGP
Part 10 : Routing in IP networks and interdomain routing with BGPOlivier Bonaventure
 
Part 9 : Congestion control and IPv6
Part 9 : Congestion control and IPv6Part 9 : Congestion control and IPv6
Part 9 : Congestion control and IPv6Olivier Bonaventure
 

More from Olivier Bonaventure (20)

Part3-reliable.pptx
Part3-reliable.pptxPart3-reliable.pptx
Part3-reliable.pptx
 
Part10-router.pptx
Part10-router.pptxPart10-router.pptx
Part10-router.pptx
 
Part1-Intro-Apps.pptx
Part1-Intro-Apps.pptxPart1-Intro-Apps.pptx
Part1-Intro-Apps.pptx
 
Part9-congestion.pptx
Part9-congestion.pptxPart9-congestion.pptx
Part9-congestion.pptx
 
Part2-Apps-Security.pptx
Part2-Apps-Security.pptxPart2-Apps-Security.pptx
Part2-Apps-Security.pptx
 
Part11-lan.pptx
Part11-lan.pptxPart11-lan.pptx
Part11-lan.pptx
 
Part5-tcp-improvements.pptx
Part5-tcp-improvements.pptxPart5-tcp-improvements.pptx
Part5-tcp-improvements.pptx
 
Part8-ibgp.pptx
Part8-ibgp.pptxPart8-ibgp.pptx
Part8-ibgp.pptx
 
Part4-reliable-tcp.pptx
Part4-reliable-tcp.pptxPart4-reliable-tcp.pptx
Part4-reliable-tcp.pptx
 
Part7-routing.pptx
Part7-routing.pptxPart7-routing.pptx
Part7-routing.pptx
 
Part6-network-routing.pptx
Part6-network-routing.pptxPart6-network-routing.pptx
Part6-network-routing.pptx
 
Part1-Intro-Apps.pptx
Part1-Intro-Apps.pptxPart1-Intro-Apps.pptx
Part1-Intro-Apps.pptx
 
Part2-Apps-Security.pptx
Part2-Apps-Security.pptxPart2-Apps-Security.pptx
Part2-Apps-Security.pptx
 
Part4-reliable-tcp.pptx
Part4-reliable-tcp.pptxPart4-reliable-tcp.pptx
Part4-reliable-tcp.pptx
 
Part3-reliable.pptx
Part3-reliable.pptxPart3-reliable.pptx
Part3-reliable.pptx
 
A personal journey towards more reproducible networking research
A personal journey towards more reproducible networking researchA personal journey towards more reproducible networking research
A personal journey towards more reproducible networking research
 
Part 12 : Local Area Networks
Part 12 : Local Area Networks Part 12 : Local Area Networks
Part 12 : Local Area Networks
 
Part 11 : Interdomain routing with BGP
Part 11 : Interdomain routing with BGPPart 11 : Interdomain routing with BGP
Part 11 : Interdomain routing with BGP
 
Part 10 : Routing in IP networks and interdomain routing with BGP
Part 10 : Routing in IP networks and interdomain routing with BGPPart 10 : Routing in IP networks and interdomain routing with BGP
Part 10 : Routing in IP networks and interdomain routing with BGP
 
Part 9 : Congestion control and IPv6
Part 9 : Congestion control and IPv6Part 9 : Congestion control and IPv6
Part 9 : Congestion control and IPv6
 

Recently uploaded

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfOrbitshub
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxRemote DBA Services
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Victor Rentea
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...apidays
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelDeepika Singh
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Angeliki Cooney
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Bhuvaneswari Subramani
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 

Recently uploaded (20)

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptx
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 

Implementing IPv6 Segment Routing in the Linux kernel

  • 1. Implementing IPv6 Segment Routing in the Linux Kernel David Lebrun, Olivier Bonaventure ICTEAM, UCLouvain, Belgium Work supported by ARC grant 12/18-054 (ARC-SDN) and a Cisco grant
  • 2. Agenda • IPv6 Segment Routing • Implementation in the Linux kernel • Performance evaluation
  • 3. Packet along shortest path to R5 What is Segment Routing ? • The return of Source Routing – Each packet contains a loose route to encode any path inside the network R1 R2 R3 R5 R7 R6 R5->R2->R6 Packet along shortest path to R2 R5->R2->R6 Normal IPv6 forwarding Normal IPv6 forwarding R2->R6 ->R6 Packet along shortest path to R6 ->R6
  • 4. IPv6 Segment Routing • Basic principles – IGP distributes IPv6 prefixes and router loopback addresses – Loose source route encoded inside IPv6 extension header containing a list of segments – Main types of segments • Node segment (router's loopback address) • Adjacency segment (router outgoing interface) • Virtual function (operator defined function) https://tools.ietf.org/html/draft-ietf-6man-segment-routing-header-06 http://www.segment-routing.net
  • 5. The IPv6 Segment Routing Header Remaining segments Each segment is one IPv6 address Index of last segment Extensibility
  • 6. IPv6 Segment Routing use cases • Paths controlled by the endhosts R1 R2 R3 R5 R7 R6 R5->R2->R6->D R5->R2->R6->D R5->R2->R6->D R5->R5->R6->D R5->R2->R6->D R5->R2->R6->D R5->R2->R6->D Source adds SRH to all packets Destination removes SRH from all packets
  • 7. Network Function Virtualisation • Force packets to pass through NFV R1 R2 R3 R5 R7 R6 R5->FCT->R6 R5->FCT->D R5->FCT->R6 R5->FCT->D FCT performed on R5 R5->FCT->D FCT
  • 8. Encap and decap • Routers can also tunnel SRH packets R1 R2 R3 R5 R7 R6 ->D R1->R5->R7->R6 [->D] ->D Ingress router encaps to R6 with SRH R1->R5->R7->R6 [->D] Egress router decaps and removes SRH R1->R5->R7->R6 [->D] R1->R5->R7->R6 [->D] R1->R5->R7->R6 [->D]
  • 9. Security: Learning from the past • How to avoid past failures of source routing ?
  • 10. The IPv6 SRH HMAC TLV Different keys and different hash functions can be used
  • 11. Utilisation of the HMAC TLV • All routers are configured with an HMAC key • Clients receive SRH with HMAC key – E.g. from SDN controlled • Trusted servers configured with HMAC key R1 R2 R3 R5 R7 R6
  • 12. Agenda • IPv6 Segment Routing • Implementation in the Linux kernel • Performance evaluation
  • 13. Basics of Linux packet processing Packet recvd for local process Packet sent by local process Forwarded packet
  • 14. Packet forwarding with IPv6 SR • Router is one of the segments in the list SRH updated, Packet forwarded to next segment
  • 15. Packet forwarding with IPv6 SR • Egress router receiving encapsulated packet SRH processed encapsulation removed
  • 16. How to configure IPv6 SR ? • IPv6 SR implementation extends iproute2 – Commands passed through rtnetlink – Example ip −6 route add fc42::/64 encap seg6 mode encap segs fc00::1,2001:db8::1,fc10::7 dev eth0 Destination match SRv6 encap Segments added in the encapsulated packet
  • 17. SRH usage by applications • Endhosts can control the SRH on a per flow basis through the socket API
  • 18. HMAC processing • Three modes of operations can be configured – Ignore • All packets are forwarded independently of the HMACs – Verify • Packets containing an HMAC are processed if HMAC is valid • Packets without HMAC are processed – Enforce • Packets containing an HMAC are processed if HMAC is valid • Packets without HMAC are discarded
  • 19. Agenda • IPv6 Segment Routing • Implementation in the Linux kernel • Performance evaluation
  • 20. Lab measurements • Lab setup – Intel Xeon X3440 processors (4 cores 8 threads at 2.53 GHz – 16 GB of RAM – two Intel 82599 10 Gbps Ethernet • One queue per CPU, one IRQ per queue – Linux kernel 4.11-rc3, TSO and GRO disabled • Traffic generator – Pktgen, in-kernel module sending UDP packets 10 Gbps Ethernet 10 Gbps Ethernet
  • 21. First measurements with one CPU Why this gap ? Baseline Plain IPv6 forwarding No difference between SRH forwarding and encap+forwarding
  • 22. Performance limitations of the first implementation • Route lookup – Destination cache was implemented for locally generated packets but not forwarded ones • Fixed with a dest cache • Issue with memory allocation – Forced free to take a slow path involving spinlocks in case packet was processed by different CPU than NIC IRQ • Fixed with a better utilisation of the skb
  • 23. Improved performance on one CPU IPv6 SRH forwarding and encap are now close to plain IPv6 packet fowarding performance
  • 24. Does packet size affect performance ? 1000 bytes 1000 bytes 64 64
  • 25. Cost of HMAC Pure C code Special intel instructions
  • 26. Leveraging multiple cores Performance scales well with the number of physical CPUS
  • 27. Conclusion • IPv6 Segment Routing has matured – Stable specification – Various use cases • Implementation in the Linux kernel 4.11+ – Endhost functions for clients and servers – Router functions • Performance evaluation – Good forwarding and encap/decap performance – Unsurprisingly HMAC TLV affects performance http://www.segment-routing.org

Editor's Notes

  1. 240k normal HMAC 290k SSE3 HMAC