For Hyper-V, the switch type determines whether a VM can reach the internet:
- External switch: connects VMs to the physical network.
- Internal switch: connects VMs to the host and other VMs on the same host, but not the external network.
- Private switch: connects only VMs on the same host.
If VMs are attached to the Default Switch and still have no internet access, a reliable workaround is to stop relying on the existing switch path and create a new network path for the VMs.
A practical fix is:
- Open an elevated PowerShell session.
- List adapters:
Get-NetAdapter - Create a new external virtual switch bound to the physical network adapter that has connectivity:
New-VMSwitch -Name <switch-name> -NetAdapterName <netadapter-name> - In Hyper-V Manager, connect each VM to that new external switch.
If the host is in a nested virtualization scenario or the external switch path does not work, use an internal switch with NAT instead. Example PowerShell flow:
New-VMSwitch -SwitchName "VM-Internal" -SwitchType Internal
New-NetIPAddress -IPAddress 192.168.100.1 -PrefixLength 24 -InterfaceIndex 34
New-NetNat -Name VM-Internal-Nat -InternalIPInterfaceAddressPrefix 192.168.100.0/24
Then configure the guest VM to use that NAT-backed network.
If a VM lost connectivity after updates, another documented workaround is to add a new network adapter to the VM, assign it to the working external switch, confirm connectivity, and then remove the old adapter.