Set up Nested Hyper-V 2016 Lab in VMWare Workstation

We recently completed a successful implementation of a virtualized IT infrastructure using VMware for one of our customer who had frequent requests to set up physical infra for them. Our customer is very much satisfied with the virtual infrastructure that we handed-over, the level of service, and the expertise that our team delivered to them.

Conceived as a Virtualization Expert, our customer requested that we go back to their site and set up a similar virtual infrastructure using Hyper-V 2016 and SCVMM, this time. How hard could it be, they asked. It should be a walk in the park for a VMware Certified Engineer, right? Not so much considering my last Hyper-V deployment was a few years back using recently released Windows Server 2012; and that’s without SCVMM and not using Hyper-V Server Core.

Anyway, there’s that for a background why I’m making myself a nested Hyper-V 2016 Lab on VMware Workstation. At the end of these series, we intend to have a highly-available, nested Hyper-V 2016 cluster with SCVMM, like this:

 

I’ve decided to break down everything that we need to do into bit size posts, and we’ll start this one with the following tasks:

  • Set up Windows Server 2016 with AD & DNS roles.
  • Set up a couple of Hyper-V 2016 Servers running on top of Windows Server 2016 Server Core
  • Install and configure some tools that we’ll use to manage our Hyper-V Servers.

Note that we’ll get all of these done inside VMware Workstation 12 Pro. We’ll also use Microsoft PowerShell as much as we can. Let’s start.

1. Download Windows Server 2016 Evaluation ISO

2. Create a Windows Server 2016 VM in VMware Workstation, and install Windows Server 2016 Standard (Desktop Experience) on it. This will be our AD named dc02.

3. Create a couple of Windows Server 2016 VMs in VMware Workstation, and install Windows Server 2016 Standard Evaluation on them. These VMs will be our Hyper-V hosts with Server core OS – hv01 & hv02.

4. Install VMware Tools on our VMs after installing the appropriate OS on them:

a. For dc02, simply click on VM > Install VMware Tools… on the menu bar of VMware Workstation.
b. For hv01 & hv02, click on VM > Install VMware Tools… on the menu bar of VMware Workstation > navigate to the CD drive letter > then enter this command at the command prompt: setup64 /S /v”/qn REBOOT=R”

5. Let’s list out the network interfaces of dc02, rename it appropriately, and then set a static IP address on it.

1
2
3
Get-NetAdapter
Rename-NetAdapter -Name Ethernet0 -NewName MgmtInt0
New-NetIPAddress -InterfaceIndex 2 -IPAddress 10.0.0.2 -AddressFamily IPv4 -PrefixLength 24 -DefaultGateway 10.0.0.1

6. Set up the first AD Forest, and DNS role on dc02.

1
2
3
Rename-Computer dc02 -Restart
Install-WindowsFeature -Name AD-Domain-Services -IncludeManagementTools
Install-ADDSForest -DomainName lab.pri -InstallDNS

7. Optional, create a reverse lookup zone after the previous step has been successfullly completed.

1
Add-DnsServerPrimaryZone -DynamicUpdate Secure -NetworkId ‘10.0.0.0/24-ReplicationScope Domain

8. Going to our Hyper-V hosts, let’s get their network interfaces, rename them, team them together, and then set a static IP address on the NIC team. While we’re at it, let’s also indicate the DNS Server IP, turn off Windows Firewall, and join the hosts to the domain.

1
2
3
4
5
6
7
8
Get-NetAdapter
Rename-NetAdapter -Name Ethernet0 -NewName MgmtInt1
Rename-NetAdapter -Name Ethernet1 -NewName MgmtInt0
New-NetLbfoTeam -Name "Mgmt Team" -TeamMembers "MgmtInt0","MgmtInt1" -TeamingMode SwitchIndependent -LoadBalancingAlgorithm Dynamic
New-NetIPAddress -InterfaceIndex 9 -IPAddress 10.0.0.20 -AddressFamily IPv4 -PrefixLength 24 -DefaultGateway 10.0.0.1
Set-DnsClientServerAddress -InterfaceIndex 9 -ServerAddresses 10.0.0.2
Set-NetFirewallProfile -Profile Domain,Public,Private -Enabled false
Add-Computer -DomainName lab.pri -Restart

Interface Index 9 is the index of the Mgmt Team interface.

Do the same for hv02 only with different IP address assigned to Mgmt Team interface. Be mindful of the Interface Index too.

9. Enable PowerShell remote connection, and add Hyper-V role on hv01 & hv02.

1
2
Enable-PSRemoting -Force
Install-WindowsFeature -Name Hyper-V -ComputerName hv01 -IncludeManagementTools -Restart

10. Install RSAT for Hyper-V on dc02.

1
Install-WindowsFeature -Name RSAT-Hyper-V-Tools -IncludeAllSubFeature

That’s it. We have ourselves a nested Hyper-V lab now that’s ready to take the beating. Check out other posts related to this new Hyper-V 2016 lab:

Configure Hyper-V 2016 Shared-nothing and Replication

Set up Hyper-V 2016 Failover Cluster

By |2018-10-07T12:54:38+00:00November 14th, 2017|Microsoft, Technology|0 Comments

About the Author:

Leave A Comment