1.

Posts Tagged ‘Activating the Server’

Activating the Server

Activating the Server

To activate our server, we can use a built-in script named slmgr.vbs found in the %windir%\System32 directory. (This script is also in Windows Vista and in full installations of Windows Server 2008, and it can be run remotely from those platforms to activate a Windows server core installation.) Typing cscript slmgr.vbs /? shows the available syntax for this command:

C:\Windows\System32>cscript slmgr.vbs /?
Windows Software Licensing Management ToolUsage: slmgr.vbs [MachineName [User Password]] [<Option>]
       MachineName:    Name of remote machine (default is local machine)
       User:           Account with required privilege on remote machine
       Password:       password for the previous account
Global Options:
-ipk <Product Key>
  Install product key (replaces existing key)
-upk
  Uninstall product key
-ato
  Activate Windows
-dli [Activation ID | All]
  Display license information (default: current license)
-dlv [Activation ID | All]
  Display detailed license information (default: current license)
-xpr
  Expiration date for current license state 

Advanced Options:
-cpky
  Clear product key from the registry (prevents disclosure attacks)
-ilc <License file>
  Install license
-rilc
  Re-install system license files
-rearm
  Reset the licensing status of the machine
-dti
  Display Installation ID for offline activation
-atp <Confirmation ID>
  Activate product with user-provided Confirmation ID

Let’s first use the –xpr option to display the expiration date for the current license state:

C:\Windows\system32>cscript slmgr.vbs -xpr
Microsoft (R) Windows Script Host Version 5.7
Copyright (C) Microsoft Corporation. All rights reserved.

Initial grace period ends 3/31/2007 1:13:00 AM

Now let’s use –dli to display more info concerning the server’s current license state:

C:\Windows\system32>cscript slmgr.vbs -dli
Microsoft (R) Windows Script Host Version 5.7
Copyright (C) Microsoft Corporation. All rights reserved. 

Name: Windows(TM) Server 2008, ServerEnterpriseCore edition
Description: Windows Operating System - Windows Server 2008, RETAIL channel
Partial Product Key: XHKDR
License Status: Initial grace period
Time remaining: 14533 minute(s) (10 day(s))

Now let’s activate the server using the –ato option:

C:\Windows\system32>cscript slmgr.vbs -ato
Microsoft (R) Windows Script Host Version 5.7
Copyright (C) Microsoft Corporation. All rights reserved.

Activating Windows(TM) Server 2008, ServerEnterpriseCore edition
  () ...
Product activated successfully.

Finally, let’s try the –xpr and –dli options again and see the result:

C:\Windows\system32>cscript slmgr.vbs -xpr
Microsoft (R) Windows Script Host Version 5.7
Copyright (C) Microsoft Corporation. All rights reserved.

The machine is permanently activated. 

C:\Windows\system32>cscript slmgr.vbs -dli
Microsoft (R) Windows Script Host Version 5.7
Copyright (C) Microsoft Corporation. All rights reserved.

Name: Windows(TM) Server code name “Longhorn”, ServerEnterpriseCore edition Description: Windows Operating System - Server code name “Longhorn”, RETAIL channel
Partial Product Key: XHKDR
License Status: Licensed
Powered by WordPress | Free WordPress News Theme by Free WordPress Themes | Thanks to Premium Themes and WordPress 3 Themes