mirror of
https://github.com/kernelkit/infix.git
synced 2026-07-30 04:33:00 +02:00
common: Use IPv4/6 default configuration on all interfaces
The comment in the script has the story.
This commit is contained in:
committed by
Joachim Wiberg
parent
c2042bb036
commit
32f6f22b47
@@ -1 +1,2 @@
|
||||
run [S] /lib/infix/sysctl-sync-ip-conf --
|
||||
run [S] /lib/infix/nameif -- Probing network interfaces
|
||||
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
#!/bin/sh
|
||||
|
||||
# When changing default IPv4/6 settings, this does not apply to
|
||||
# existing interfaces. This syncs the default settings to all known
|
||||
# interfaces at boot, such that physical interfaces will start from
|
||||
# the same point as virtual ones.
|
||||
|
||||
sysctl net.ipv4.conf.default >/tmp/sysctl-ip-default
|
||||
sysctl net.ipv6.conf.default >>/tmp/sysctl-ip-default
|
||||
|
||||
for iface in $(ip -j link show | jq -r .[].ifname); do
|
||||
sed -e "s/.default./.${iface}./g" /tmp/sysctl-ip-default \
|
||||
| sysctl -p -
|
||||
done
|
||||
Reference in New Issue
Block a user