Linux disable ipv6
It's possible to simpy disable ipv6 if you have any issues , but it's more preferred to to set the precedence to ipv4 instead of mostly systems default ipv6 protocol. See details: http://wiki.vpsget.com/index.php/Prefer_IPv4_over_ipv6_._How_to_set_ipv4_precedence
To disable ipv6 edit file /etc/sysctl.conf,
vi /etc/sysctl.conf
Add the following lines:
net.ipv6.conf.all.disable_ipv6 = 1 net.ipv6.conf.default.disable_ipv6 = 1
Save and apply settings:
sysctl -p
You may also simply run these commands:
echo 1 > /proc/sys/net/ipv6/conf/all/disable_ipv6 echo 1 > /proc/sys/net/ipv6/conf/default/disable_ipv6
Or
sysctl -w net.ipv6.conf.all.disable_ipv6=1 sysctl -w net.ipv6.conf.default.disable_ipv6=1
This should work on mostly all linux related distros . Tested on Centos and Ubuntu.
""