Workaround for customization failure due to rearm count down to zero
search cancel

Workaround for customization failure due to rearm count down to zero

book

Article ID: 330137

calendar_today

Updated On:

Products

VMware vCenter Server

Issue/Introduction

Best practice to clone and customize a windows Virtual Machine.

Symptoms:
  • Windows customization fails due to Sysprep complaining that there are no more rearms available, which is usually happen for Windows7 and Windows 2008 OS.
 
Customization fails and there is error message like “A fatal error occurred while trying to Sysprep the machine.”  and with the following in customization logs:
Error [0x0f0082] SYSPRP LaunchDll: Failure occurred while executing 'C:\Windows\System32\slc.dll, SLReArmWindows', returned error code -1073425657


Cause

Windows 7/Windows 2008 system by design has a rearm count of 3 after fresh install. This rearm count will be slip by 1 for each VM clone operation. And It will also slip by 1 for each “sysprep/generalize” operation which is part of windows customization process. And it will drop to 1 directly if activated by KMS server.

There are two scenarios customer may face this issue:
  1. Repeated clone and customize a Windows template VM in chain. Some customer will clone and customize a windows GOS from a base template (Base VM->clone1, rearm count is 2). Then do clone and customize of this cloned VM (clone1->clone2, rearm count is 1). Then clone and customize it again and again which will make rearm count to 0 and result in customization failure.
  2. Clone and customize a Windows template VM already activated by KMS server. Windows VMs activated by KMS server has rearm count of 1. Clone and then customize  the cloned VM will fail to sysprep.

Resolution

To workaround this issue,
  1. Post vSphere 6.5 is to clone template VM without doing customization.
  2. Run KMS activation manually since NICs are connected before customization.
  3. Run VM customization will PASS.
  4. Commands to activate VMs via KMS server.
cscript \windows\system32\slmgr.vbs -skms YOUR_KMS_SERVER_ADDRESS
cscript \windows\system32\slmgr.vbs -ato


Additional Information

This affects Windows7 and Windows Server 2008/Windows Server 2008 R2 OS
This is usually not found for Windows 8/8.1, Windows 10, Windows Server 2012/Windows Server 2012R2, Windows 2016 OS. As these newer windows OS usually have large rearm count for “1000” if activated by KMS.