Kevin Remde's IT Pro Weblog
IT Pro Resources
TechNet EventsMicrosoft Security Response CenterTechNet IT Manager Community HubMicrosoft Virtual AcademyKevin’s Evaluation Download Center
IT Pro Evangelist Blogs
Blain Barton Blain Barton's Blog@BlainBar
Brian LewisMy Thoughts on IT...@BrianLewis_
Dan Stolts IT Pro Guru Blog@ITProGuru
Jennelle Crothers TechBunny@jkc137
Keith MayerIT Pros ROCK!@KeithMayer
Kevin Remde Full of I.T.@KevinRemde
Matt Hester Matthew Hester's WebLog@MatthewHester
Tommy PattersonVirtually Cloud 9@Tommy_Patterson
Yung Chou Yung Chou on Hybrid Cloud@YungChou
At our Columbus, Ohio TechNet Event, Karl asked:
Great question, Karl. And I have seen two ways to do this well.
Way #1 – Treat your test network as a subnet that requires routing.
Although this method is more complex, I personally prefer it. It treats the “Internal” network as a separate subnet, which is more real-world to me. You can set up your own mini-company inside of the subnet, and have control over DHCP or other subnet-bound broadcast protocols. Basically for this method you are going to treat your physical Hyper-V host as a router which does NAT (Network Address Translation) for you.
The steps are:
1. Add the Network-Policy and Access Services – Routing and Remote Access on the physical host machine. All you need is love NAT.
2. Create a new Hyper-V Network switch of type “Internal”. I just name mine “Internal”.
3. For the adapter that appears in your Network Connections associated with that new Hyper-V network, set the addressing to something you’ll remember. The address used here will be used as the “gateway address” for the machines connecting to it to give them Internet access, so common convention would recommend setting it to xxx.xxx.xxx.1 (192.168.10.1 or 10.0.0.1. Whatever you want. Since it’s unlikely you’ll be using more than 254 addresses for this test subnet, you could go with a 24-bit mask (255.255.255.0) for this subnet, too.) If you plan to have a Domain Controller and/or a DNS server in your subnet, you can add that address as the preferred DNS server.
4. Now in the configuration of Routing and Remote Access, you’ll set up NAT by right-clicking on NAT, choosing “New Interface…”, selecting the interfaces, and setting their Interface Type correctly. The important one is the Wireless Network Connection, which you set as Public, and enable NAT on the interface.
And the other network adapters (including “Internal” will be defined as Internal. (duh). Eventually the configuration will look something like this.
Now, as long as the virtual machines are connected to my “Internal” switch, and have their networking and default gateway set correctly, they’ll be able to get to the Internet.
Way #2 – Use a Network Adapter Bridge
Though not as real-world (my opinion) as using routing, this is definitely the easier way to do it. In your Network Connections, CTRL+CLICK to select both the wireless and wired adapter. Then right-click either one and you should see a “Bridge Connections” option. Pick it. Now whatever virtual network switch you’ve bridged with the wireless adapter should be able to get out to the outside world.
Is this useful? Do you have other tricks that have worked that you want to share with us? Let us know in the comments.