Problem Deploying a Windows Server 2008 R2 VM Guest using a KMS Server with VMware vCenter

We've been having problems deploying Windows Server 2008 R2 virtual machines from templates using the VMware vCenter and it's built in guest customization.

It appears that there may be an issue either with Microsoft's built-in sysprep utility in 2008 R2, or with VMware's vCenter guest customization wizard when using a Key Management Server, or KMS. A KMS is part of Microsoft's Volume Activation 2.0 as described here - http://www.microsoft.com/licensing/existing-customers/product-activation... and in this TechNet article - http://technet.microsoft.com/en-us/library/bb892849.aspx

When I would run through the vCenter guest customization wizard I would enter all the proper information and I know our KMS key works because we use an automated installation process with Windows Deployment Services (WDS) and PXE to build physical machines and virtual machines which we convert to templates.

After using the guest customization I would receive the following error when the 2008 R2 VM would try to finish the sysprep phase of customization:


Windows could not parse or process the unattend answer file for pass [specialize]. The settings specified in the answer file cannot be applied. The error was detected while processing the settings for component [Microsoft-Windows-Shell-Setup].

We currently have a support request open with VMware to determine if this is a sysprep problem, or a vCenter issue. I will update this article when we have more information.

Until that time, the solution is to not enter a product key in the guest customization wizard IF you have a KMS AND you are joining your VM to an Active Directory domain. Your server should sysprep fine and then find the KMS SRV record in your DNS and should active just fine.