3

I am aware of the grub kernel params method but I'd like to understand why the sysctl approach is not working.

On a 20.04 server if I add net.ipv6.conf.(all|default|lo).disable_ipv6=1 (presumably ".all." should be enough), to /etc/sysctl.conf (or a separate /etc/sysctl.d/ file), on boot it only disables ipv6 on the loopback, the main interface still has it.

Since it works for loopback, the sysctl conf files are being processed on boot.

0

Sadly, there are many myths about how to disable IPv6 on Ubuntu and the Ubuntu project itself hasn't provided a canonical solution going as far back as Ubuntu 16.04.

The best solution that I've found so far is to modify the Kernel commandline via Grub and reboot the system. See here:

https://askubuntu.com/a/337736/266

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.