4

When connecting to vagrant, I get an IPv6 address.

    default: IP: fe80::215:5dff:fe38:151
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: fe80::215:5dff:fe38:151:22

After reading a lot of articles saying that you should disable IPv6, I tried to do so.

I tried using the script that Microsoft provides. ( https://support.microsoft.com/en-us/help/929852/how-to-disable-ipv6-or-its-components-in-windows )

Which didn't result in getting an IPv4 address also I tried disabling it via the registry. ( http://tweaks.com/windows/40099/how-to-properly-disable-ipv6/ )

I got an IPv4 address once but after reboot I got an IPv6 address again.

Any idea's on how to solve this?

4
  • 1
    Please be aware that Microsoft explicitly does not support systems with IPv6 disabled. If you need a supported configuration you might want/need to solve this on the vagrant side. Commented Oct 29, 2017 at 7:47
  • 3
    IPv4 and IPv6 addresses are not mutually exclusive and are designed to coexist in peace. Disabling IPv6 does not mean that you will get an IPv4 address instead. If your problem is that your IPv4 address is missing, you should try to find the cause for this, but disabling IPv6 doesn't help at all. Commented Oct 29, 2017 at 8:39
  • This looks like a bug in Vagrant, not a misconfiguration. You should have a chat with the Vagrant developers about the proper use of IPv6 address scopes, which they haven't done. Commented Nov 15, 2018 at 14:20
  • @SanderSteffann Not using Vagrant, how would this apply to an Ubuntu VM under Hyper-V where IPv6 is already disabled on Ubuntu? I'm seeing Windows assign both an IPv4 and IPv6 address, which is causing issues because periodically Windows (apparently) decides to use IPv6 to talk to the SMB share on the VM, and of course it doesn't answer, causing the share to disappear while in use.
    – Michael
    Commented Oct 5, 2022 at 22:28

2 Answers 2

1

You can edit each network adapter and uncheck the IP6 binding; in your case edit the Hyper-V Virtual adapter. You may need to reboot for it to take effect. You should no longer have an IP6 address assigned to the adapter. Note you technically have a build Micorosft can say they will not support, but if that is the case, you can re-enable it for the support call. Good luck!

2
  • After doing this I still see (from the get-vm command in Powershell) that the VM has both an IPv4 and IPv6 address.
    – Michael
    Commented Oct 5, 2022 at 22:24
  • And yes, this is after a reboot.
    – Michael
    Commented Oct 5, 2022 at 22:38
0

I have the same issue, but solution may not suite for your case. Docker for windows installed with Hyper-V. then you vagrant up a hyperv box will assign a IPv6 address. after unintall the docker. vagrant can obtain correct IPv4 address. Hope this can help.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .