To enable SRv6 support, at least CONFIG_IPV6
must be enabled. The default built-in SRv6 code supports elementary processing of SR-enabled packets. For extended features such as SR encapsulation or other advanced processing, enable CONFIG_IPV6_SEG6_LWTUNNEL
. The HMAC extension of SRv6 can be enabled through CONFIG_IPV6_SEG6_HMAC
. To use iptables to filter packets on their SRv6 header, enable CONFIG_IP6_NF_MATCH_SRH
(available since kernel v4.18). Finally, the BPF network functions can be enabled through CONFIG_IPV6_SEG6_BPF
(available since kernel v4.18).
Today most of the recent distributions compile the kernel with CONFIG_IPV6_SEG6_LWTUNNEL
and CONFIG_IPV6_SEG6_HMAC
:
- Debian (since 10) - Fedora (since 24) - Raspbian (since 2018-04-18) - Ubuntu (since 18.04) - [...]
CONFIG_IPV6_SEG6_BPF
is enabled in:
- Debian (since 10) - Fedora (since 27)
Fedora (since 27) is the only one enabling CONFIG_IP6_NF_MATCH_SRH
as well.
ubuntu19.10-aarch64 [root@localhost uloop3]# cat boot/config-5.3.0-18-generic | grep IPV6_SEG6 CONFIG_IPV6_SEG6_LWTUNNEL=y CONFIG_IPV6_SEG6_HMAC=y CONFIG_IPV6_SEG6_BPF=y [root@localhost uloop3]# cat boot/config-5.3.0-18-generic | grep MATCH_SRH CONFIG_IP6_NF_MATCH_SRH=m
centos8
[root@localhost ~]# uname -a Linux localhost.localdomain 4.18.0-147.3.1.el8_1.x86_64 #1 SMP Fri Jan 3 23:55:26 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux [root@localhost ~]# [root@localhost ~]# cat /boot/config-`uname -r` | grep grep IPV6_SEG6 grep: IPV6_SEG6: No such file or directory [root@localhost ~]# cat /boot/config-`uname -r` | grep IPV6_SEG6 # CONFIG_IPV6_SEG6_LWTUNNEL is not set # CONFIG_IPV6_SEG6_HMAC is not set [root@localhost ~]# cat /boot/config-`uname -r` | grep MATCH_SRH # CONFIG_IP6_NF_MATCH_SRH is not set