Every time I am configuring a Debian or Centos machine with a static IP address, I forget about that behavior of not taking in account my IPV4 configuration. Then, I search for the 1000th time the parameter to put in sysctl.conf to disable IPV6, and finally I reboot the beast.
An example to illustrate :
Linux deb-router 3.2.0-4-amd64 #1 SMP Debian 3.2.81-2 x86_64 GNU/Linux
It has 2 interfaces; eth0 is configured in IPV4 for some time (1 year maybe).
ETH1 is bridged on my physical network and was addressed by the DHCP, in IPV4. I talk to the VM through this interface.
Tonight I lost my Internet gateway; this device is also my DHCP server.
I realized I cannot reach my VM anymore, so I checked ifconfig and saw a nice IPV6 instead of the old IPV4 bound to ETH1.
So, action !
$ sudo vim /etc/network/interfaces
allow-hotplug eth1
# was dhcp before
iface eth1 inet static
address 192.168.0.15
netmask 255.255.255.0
$ sudo ifdown eth1 && sudo ifup eth1
Deception :(
ifconfig outputs only an ipv6; I cannot reach my VM. I must disable IPV6 (net.ipv6.conf.eth1.disable_ipv6 = 1), and reboot, to get the connection back.
I don't understand this choice to favor IPV6 over IPV4: Most of people are working with IPV4, from what I know.
Is it technical, or is it political to influence people to adopt IPV6 ?
/etc/gai.conf# For sites which prefer IPv4 connections change the last line to ` precedence ::ffff:0:0/96 100`; it could well be your IPv6 network infra-structure is broken...once here in the beginnings of the IPv6 project everything was well with the IPv4 firewall rules, but IPv6 was not that well tested.fe80::20c:29ff:febe:d6fais a link-local address. Every interface has one, and it's only usable on your local LAN. It's not a routable IPv6 address. Why your IPv4 wasn't working: no idea, sounds like a bug somewhere. The information you provide is not enough to determine the cause. But having IPv6 enabled isn't it, that assumption is almost certainly wrong.