Q: What is VM Generation ID in Windows Server 2012 Hyper-V?
Windows Server 2012 Hyper-V adds VM Generation ID to detect changes to a VM's place in time.
August 11, 2012
A: VM Generation ID is a new virtual machine (VM) attribute in Windows Server 2012 Hyper-V that's used to enable specific applications running in a VM to detect if something has happened to the VM to affect its "place in time."
As an example, look at a domain controller (DC), the key service that uses the VM Generation ID (at the time this FAQ was written). Taking a snapshot of a DC VM then applying that snapshot later on is a very bad practice, as it moves that DC back in time. This results in identifiers being reused, causing security and replication problems (this stems from the fact the DC has no idea that a snapshot was applied).
With the VM Generation ID, anytime an operation on the VM occurs that changes that VM's place in time (moving it backwards), then Hyper-V will change the VM Generation ID of the VM. Such an operation could include a snapshot being applied, a VM being imported, or a restore occurring from a backup of the VM, and more.
The change in the VM Generation ID allows services to constantly compare their cached value of VM Generation ID (ms-DS-Generation-Id for AD) to the actual VM Generation ID of the VM. If they don't match, the service knows something has happened to the VM's place in time and can react accordingly.
In the case of DCs, if the VM Generation ID changes, then the DC will invalidate its RID pool and changes to invocation ID for the Active Directory (AD) database (such as the database identifier), which stops duplicate security ID objects being created and ensures proper replication.
About the Author
You May Also Like