===== Disable IPv6 =====
==== RHEL ====
Without restart:
echo 1 > /proc/sys/net/ipv6/conf/all/disable_ipv6
echo 1 > /proc/sys/net/ipv6/conf/default/disable_ipv6
Permanent changes:
Edit /etc/modprobe.d/ipv6.conf:
options ipv6 disable=1
Edit /etc/sysctl.conf:
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
Finally:
cp -p /etc/hosts /etc/hosts.disableipv6
sed -i 's/^[[:space:]]*::/#::/' /etc/hosts
==== References ====
* http://beforeitsnews.com/opinion-liberal/2012/08/how-to-disable-ipv6-on-rhel-centos-2445758.html
* https://access.redhat.com/solutions/8709