On Ubuntu 14.04.1 and 12.04.2, for the IPv6 interface to function, one has to add the lines:
up ip route add default via fe80::1 dev eth0
down ip route del default via fe80::1 dev eth0
in /etc/network/interfaces
But Virtualmin 4.11.gpl removes them every time one adds or deletes a virtual host. IPv6 then no longer works until one manually runs the command:
ip route add default via fe80::1 dev eth0
For example, one edits /etc/network/interfaces so the IPv6 section reads like this:
iface eth0 inet6 static
pre-up /sbin/modprobe -q ipv6 ; /bin/true
address 2a01:xxx:192:31d0::2
netmask 64
up ip route add default via fe80::1 dev eth0
down ip route del default via fe80::1 dev eth0
up ifconfig eth0 inet6 add 2a01:xxx:192:31d0::3/64
up ifconfig eth0 inet6 add 2a01:xxx:192:31d0::4/64
...
...
After adding/deleting a virtual host, when Virtualmin adds or removes the allocated IPv6 line of the virtual host, it becomes
iface eth0 inet6 static
pre-up /sbin/modprobe -q ipv6 ; /bin/true
address 2a01:xxx:192:31d0::2
netmask 64
up ifconfig eth0 inet6 add 2a01:xxx:192:31d0::3/64
up ifconfig eth0 inet6 add 2a01:xxx:192:31d0::4/64
...
...
I.e. the command ip route add default via fe80::1 dev eth0 is removed even though it was previously manually added.
This appears to be a new bug, because previous versions of Virtualmin did not cause this issue.
It would make more sense if Virtualmin only modified entries it added itself during the creation of a virtual host and left alone any manual modifications in the file made by the administrator.
Comments
Submitted by JamieCameron on Fri, 10/10/2014 - 11:11 Comment #1
Are there some docs on why this
up ip route
line is needed? I can modify Webmin to add it, but I'd expect that Debian would do this automatically if any IPv6 addresses are active.Submitted by Joncas on Fri, 10/10/2014 - 12:05 Comment #2
I don't know about official doc, but the fact is that none of my IPv6 addresses work without that command (ip route add default via fe80::1)
On various forums and in the Hetzner.de wiki it is also explained as a needed step:
http://www.memset.com/docs/managing-your-server/ipv6/network-configuration/
http://wiki.hetzner.de/index.php/Zusaetzliche_IP-Adressen/en#Dedicated_S...
To activate additional IP4 addresses I also have to add :
up ip addr add 144.xxx.yyy.216/32 dev eth0
down ip addr del 144.xxx.yyy.216/32 dev eth0
up ip addr add 144.xxx.yyy.218/32 dev eth0
down ip addr del 144.xxx.yyy.218/32 dev eth0
up ip addr add 144.xxx.yyy.219/32 dev eth0
down ip addr del 144.xxx.yyy.219/32 dev eth0
.
Wouldn't it make sense in general to let users customize /etc/network/interfaces and have Virtualmin only affect the additional private IPv6 it adds at the end?
Submitted by JamieCameron on Fri, 10/10/2014 - 19:33 Comment #3
Good point - this will be fixed in the next Webmin release.
Submitted by Issues on Fri, 10/24/2014 - 19:40 Comment #4
Automatically closed -- issue fixed for 2 weeks with no activity.