I want to disable IPV6 in the new Centos6 virtual server I have just setup in Xen. I have already followed the instructions here and then rebooted/restarted networking.
Update: followed the below, that seems to have worked, but now it hasn't picked up an ipv4 address?
eth0 Link encap:Ethernet HWaddr 9A:F0:43:47:04:F1
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:941 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:89952 (87.8 KiB) TX bytes:0 (0.0 b)
Interrupt:14
You need to make changes in a few different places.
First, disable IPv6 in the user-land network configuration scripts by modifying the file
/etc/sysconfig/network
Make sure to set the variable
NETWORKING_IPV6=no
Next disable the ipv6 kernel module. You should be able to create a new modprobe.d file to disable it, or outright blacklist it. So either
/etc/modprobe.d/ipv6.conf
containing/etc/modprobe.d/blacklist.conf
IPTables is enabled by default, and has a separate service for IPv4 and v6, so we need to disable the v6 version as well.
In theory, once all this is set up, you should be able to restart networking, and unload the module. However, you may require a full reboot to make sure all the cruft is cleaned up. After doing this I would recommend verifying that the disable took by looking at the loaded modules, your running network config, listening/sockets, etc for any v6 indicators.