I've got Windows 8 Pro on my home machine. I want to have a Windows 7 Professional VM running under Hyper-V, and I want the VM to have full internet access. My physical machine has a wireless network adapter I use to connect to a router.
Here's what I've done so far:
In Hyper-V Manager, I've created a new External Virtual Switch, which is connected to my wireless network adapter. If I look in Windows 8's Network Connections page, I can see it's created a virtual ethernet adapter and a network bridge, and my wireless adapter is now bridged.
I've created a Windows 7 VM, and in the Hyper-V settings I've set it to use the virtual switch.
When I log into the VM, I have a network, but it's "unidentified" and has no internet access. What am I missing? Is it something to do with the "VLAN identification" settings? I'm not quite sure what these are about.
This question was a Super User Question of the Week.
Read the blog entry for more details or contribute to the blog yourself
Answer
In order to get the VM connected to the internet you have to tie it to the Ethernet/Wireless NIC Card. In order to do this you have to create a "Virtual Switch".
- Open your Hyper-V Manager
Select
Action
-->Virtual Switch Manager
Select
External
and thenCreate Virtual Switch
Give the Switch a Name and then select the External Controller you use to connect to the internet (Ethernet, or Wireless NIC, etc,.)
Note: You must select the way that you are actually connecting to the internet. IE, if your computer is set up to use Wifi or Ethernet, but is currently using Ethernet, you must use Ethernet - the Wifi connection will not work because the host machine isn't currently using it.
Select
Apply
and thenOK
Right click on the Virtual Machine you want to connect and select
Settings
Under the
Network Adapter
Setting select the newly created Virtual Switch
This should enable the connection you use to connect to the internet to be accessible to the VM
Note: you may have to do a ipconfig /release
and ipconfig /renew
(Windows) or a sudo dhclient -v -r
and sudo dhclient -v
(Linux) on the remote machine to get it to renew its DHCP settings and retrieve an IP address.
No comments:
Post a Comment