On Sat, Jul 5, 2014 at 4:01 PM, Jouke Witteveen <[email protected]> wrote: > --- > It was proposed to disable IPv6 entirely in case of "IP6=no". > Currently we only disable processing of router advertisements. > This looks OK to me, but I would really like to get some feedback on > this one, as I cannot extensively test the consequences. > src/lib/ip | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/src/lib/ip b/src/lib/ip > index 66aab56..9600504 100644 > --- a/src/lib/ip > +++ b/src/lib/ip > @@ -47,11 +47,12 @@ ip_set() { > case "$IP6" in > dhcp*|stateless|static) > [[ -d "/proc/sys/net/ipv6" ]] || modprobe ipv6 > + sysctl -q -w "net.ipv6.conf.$interface_sysctl.disable_ipv6=0" > [[ $IP6 == "static" ]] > sysctl -q -w "net.ipv6.conf.$interface_sysctl.accept_ra=$?" > ;; > no) > - [[ -d "/proc/sys/net/ipv6" ]] && sysctl -q -w > "net.ipv6.conf.$interface_sysctl.accept_ra=0" > + [[ -d "/proc/sys/net/ipv6" ]] && sysctl -q -w > "net.ipv6.conf.$interface_sysctl.disable_ipv6=0"
That would be disable_ipv6=1, of course. > ;; > "") # undefined IP6 does not prevent RA's from being received -> nop > ;; > -- > 2.0.1 >
