Which edition to install
In the earlier versions of Windows Server with Hyper-V, there were huge differences among the different available editions. Some features and hardware requirements were only available on Enterprise and Datacenter editions of Windows Server. Almost all the features and hardware specifications are available even with the Standard edition of Windows Server 2012 R2, so there is no need to use an Enterprise edition (which was dropped by Microsoft earlier). The main difference between the Standard and Datacenter editions relies on the virtualization rights. Each Windows Server Standard edition allows you to run two guest Operating System Environments (OSEs) with Windows Server editions, and a Datacenter edition allows you to run an unlimited number of Windows Server VMs on this particular licensed Hyper-V host. There is only one technical difference between the two editions: on a Datacenter edition, all Windows Server guest VMs will be automatically activated, when provided with a corresponding key during setup. There is no need for a MAK or KMS-based OS activation anymore.
Basically, it's not very important which edition you choose for the host install, so stick to Windows Server 2012 R2 Standard. If you want to leverage Automatic Virtual Machine Activation (AVMA), install a Datacenter edition on the host. It is easy to upgrade a Standard edition later to a Datacenter edition, but there is no downgrade option.
If you are not sure which edition you are using, open a PowerShell window with administrative privileges and run the following command:
get-windowsedition –online
To find out which editions are available for upgrade, run the following command:
Get-WindowsEdition –online –target
Finally, to upgrade to the target edition, run the following command:
Set-WindowsEdition –online –edition ServerDatacenter
While it's suitable to install a Datacenter edition on a Hyper-V host, you should never do this inside a virtual machine. Installing Standard editions into virtual machines always gives you an easy way to move this VM at a later time to a non-Datacenter Hyper-V host.
The next step to build our unattended installation is to set up the installation target and edition. Navigate to the ImageInstall
string under the Microsoft-Windows-Setup
node and add the following code:
<ImageInstall><OSImage><InstallFrom><MetaData wcm:action="add"><Key>/Image/Name</Key><Value>Windows Server 2012 R2 SERVERSTANDARD</Value></MetaData></InstallFrom><InstallTo><DiskID>0</DiskID><PartitionID>2</PartitionID></InstallTo></OSImage></ImageInstall>
If you have chosen the UEFI-based setup, choose PartitionID 4
according to your disk setup. This will make sure that you install the Standard edition of Windows Server 2012 R2 to the correct partition.
As the last step in Pass1
, we will fill out the UserData
tree under the Microsoft-Windows-Setup
node and edit the following code:
<UserData><ProductKey><WillShowUI>OnError</WillShowUI></ProductKey><AcceptEula>true</AcceptEula><FullName>YourName</FullName><Organization>YourOrg</Organization></UserData>
Fill in Name and Org Data with anything you like; however, these fields are mandatory. The product key field is optional. If you intend to use a 180-day trial version of Windows Server or are leveraging KMS Server activation capabilities, do not enter a product key. If you are using MAK-based OS activations, enter your product key. You can also install a MAK product key at a later time by opening a PowerShell window with administrative privileges and running the following command:
slmgr –upk (this uninstalls the current product key) and
slmgr –ipk <key> (including dashes)