Last Update: Sep 04, 2024 | Published: Feb 12, 2014
Today I will discuss how you can use a new feature in Windows Server 2012 R2 Hyper-V called Automatic Virtual Machine Activation (AVMA) to automatically activate the guest OS installations of Hyper-V virtual machines.
Imagine a Hyper-V installation that is large or complex. There might be many isolated networks. Those networks could be isolated using either VLANs or Hyper-V Network Virtualization (HNV). There might be many Active Directory forests that have no external trusts. These are very real designs that must be implemented by large enterprises and hosting companies that are building multi-tenant clouds.
Anyone who has legally deployed Windows (hopefully that is all of you) since the days of Windows XP has had to activate their product key. There are three ways to do an activation:
Initially it sounds like KMS activation is the perfect approach to use in a large-scale virtualization environment. In fact, it will work pretty well for a flat network where all virtual machines are in the same network or Active Directory as the hosting infrastructure where the KMS will likely reside.
But think about a true cloud for a moment, with its multi-tenancy, self-service, and broad network access. Lots of non-IT staff (I don’t mean the receptionist, but delegated IT outside of central infrastructure management) will be deploying virtual machines for themselves. Tenants, be they internal or external, must be isolated from the hosting infrastructure and each other. And how are the Windows Server operating systems of those virtual machines going to activate against a centrally deployed KMS server with which they cannot communicate?
You may have heard the line that “every Hyper-V feature of Windows Server Datacenter edition is in Windows Server Standard.” That was true in WS2012 and it is very nearly true in WS2012 R2. The one exception is related to licensing.
When you license a physical server with Windows Server Datacenter edition you are entitled to install it:
That makes licensing hosts (including vSphere) using the Datacenter edition the cheapest option for deploying hosts with lots of Windows Server virtual machines – you basically get unlimited installs of Windows Server on that host for the cost of licensing just the physical server for Window Server.
And this is why Microsoft added AVMA to just the Datacenter edition. AVMA provides a solution in which:
In short, AVMA simplifies Windows Server activation for larger deployments and for networks that must feature virtual machine isolation. The OS requirements are:
There are two ways to deploy the AVMA key. The first is a more manual process in which you run the following command in the guest OS of a new virtual machine:
slmgr /ipk <AVMA_product_key>
Note: You can get the public (yes, they are public and intended to be used by everyone) AVMA product keys from TechNet.
The guest OS will communicate with the host via the Hyper-V integration components to attempt an activation. This process is repeated every seven days to ensure that mobile VMs are indeed running on activated hosts.
If you want to build lots of virtual machines, such as in a self-service cloud, then you should consider the alternative approach in which you include the AVMA product key in the unattended installation. This will remove the manual aspect of running SLMGR.