I use multipass 1.5.0 on Windows 10 with Hyper-V and I observe that an IPv6 address works correctly from the host or from a non multipass VM but interface name must be added between multipass VMs.
There is a work around for ping command because it handles an extended IPv6 syntax with a suffix like %eth0 to designate the interface to use. But programs that use standard IPv6 syntax cannot work.
Procedure to reproduce the problem:
Create 2 multipass VMs:
C:\Users\tfavi\Documents\safe\bin>multipass launch -n V1
Launched: V1
C:\Users\tfavi\Documents\safe\bin>multipass launch -n V2
Launched: V2
Get IPv6 address of V1 on eth0:
C:\Users\tfavi\Documents\safe\bin>multipass exec V1 -- ip addr show dev eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether 00:15:5d:01:4d:84 brd ff:ff:ff:ff:ff:ff
inet 172.27.104.82/20 brd 172.27.111.255 scope global dynamic eth0
valid_lft 85627sec preferred_lft 85627sec
inet6 fe80::215:5dff:fe01:4d84/64 scope link
valid_lft forever preferred_lft forever
Ping V1 from host (successful without interface name):
C:\Users\tfavi\Documents\safe\bin>ping -6 fe80::215:5dff:fe01:4d84
Envoi d’une requête 'Ping' fe80::215:5dff:fe01:4d84 avec 32 octets de données :
RĂ©ponse de fe80::215:5dff:fe01:4d84 : temps<1ms
RĂ©ponse de fe80::215:5dff:fe01:4d84 : temps<1ms
RĂ©ponse de fe80::215:5dff:fe01:4d84 : temps<1ms
RĂ©ponse de fe80::215:5dff:fe01:4d84 : temps<1ms
Statistiques Ping pour fe80::215:5dff:fe01:4d84:
Paquets : envoyés = 4, reçus = 4, perdus = 0 (perte 0%),
Durée approximative des boucles en millisecondes :
Minimum = 0ms, Maximum = 0ms, Moyenne = 0ms
Ping V1 from V2 (successful with interface name but failed without it):
C:\Users\tfavi\Documents\safe\bin>multipass exec V2 -- ping -c4 -6 fe80::215:5dff:fe01:4d84%eth0
PING fe80::215:5dff:fe01:4d84%eth0(fe80::215:5dff:fe01:4d84%eth0) 56 data bytes
64 bytes from fe80::215:5dff:fe01:4d84%eth0: icmp_seq=1 ttl=64 time=0.513 ms
64 bytes from fe80::215:5dff:fe01:4d84%eth0: icmp_seq=2 ttl=64 time=0.642 ms
64 bytes from fe80::215:5dff:fe01:4d84%eth0: icmp_seq=3 ttl=64 time=0.691 ms
64 bytes from fe80::215:5dff:fe01:4d84%eth0: icmp_seq=4 ttl=64 time=0.703 ms
--- fe80::215:5dff:fe01:4d84%eth0 ping statistics ---
4 packets transmitted, 4 received, 0% packet loss, time 3077ms
rtt min/avg/max/mdev = 0.513/0.637/0.703/0.075 ms
C:\Users\tfavi\Documents\safe\bin>multipass exec V2 -- ping -c4 -6 fe80::215:5dff:fe01:4d84
PING fe80::215:5dff:fe01:4d84(fe80::215:5dff:fe01:4d84) 56 data bytes
ping: sendmsg: Invalid argument
ping: sendmsg: Invalid argument
ping: sendmsg: Invalid argument
ping: sendmsg: Invalid argument
--- fe80::215:5dff:fe01:4d84 ping statistics ---
4 packets transmitted, 0 received, 100% packet loss, time 3061ms
Ping V1 from a non multipass VM (Windows 10 VM) added to Hyper-V (successful without interface name):
C:\Users\User>ping -6 fe80::215:5dff:fe01:4d84
Pinging fe80::215:5dff:fe01:4d84 with 32 bytes of data:
Reply from fe80::215:5dff:fe01:4d84: time=1ms
Reply from fe80::215:5dff:fe01:4d84: time<1ms
Reply from fe80::215:5dff:fe01:4d84: time<1ms
Reply from fe80::215:5dff:fe01:4d84: time<1ms
Ping statistics for fe80::215:5dff:fe01:4d84:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 1ms, Average = 0ms
Note: Hyper-V doesn’t show any differences in the network adapter parameters of multipass VMs and the Windows 10 VM:
Do I have to modify something in my multipass VMs to make a standard IPv6 address works ? or is it a bug ?