Sysctl
The sysctl statement allows to configure network-related sysctl settings which are not interface specific.
- sysctl.all - configures all interface-specific settings
- sysctl.default - configures the interface-specific default settings
- sysctl.mpls - configures MPLS1 settings
# https://www.kernel.org/doc/Documentation/networking/ip-sysctl.txt
sysctl:
all:
# /proc/sys/net/ipv4/conf/all/
ipv4:
forwarding: 1
default:
# /proc/sys/net/ipv4/conf/default/
ipv4:
forwarding: 1
# /proc/sys/net/mpls/
# https://www.kernel.org/doc/Documentation/networking/mpls-sysctl.txt
mpls:
# set greater 0 to enable mpls forwarding
platform_labels: 1024
The settings can be also configured inside of namespaces.
Tip
YAML has native support for anchors and aliases which can be used to apply the same sysctl settings to multiple namespaces:
Examples:
-
Multiprotocol Label Switching ↩