Windows: Key Management Service – Software Licensing Manager

Created: 12/12/19

In my travels I’ve used the slmgr.vbs script for activations, and wrote up a similar article on this, but with the recent push into the MCSE, figured I’d right this up for myself and maybe others; if I don’t I’ll forget it.

typing this command in command prompt is usually where I do this, though you can do it in powershell too.

below  the switches are as follows and come after slmgr.vbs <insert switch below>

/ato – this one attempt to do a online activation

/cdns – allows you to disable the KMS automated DNS publishing

/sdns – allows you to enable the KMS automated DNS publishing

/dli – show the current KMS activation count

/dlv – show detailed information about the licensing on the current system

/ipk is using when you have a product key; the product key would come right after the command like ‘/ipk XXXXX-XXXXX-XXXXX-XXXXX-XXXXX’ – make sure you place the – in between the keys entered

/sprt PortNumber – this allows you to change the default port of 1688 to something else

/sri RenewalInterval – this allows you set how often the KMS client attempts to renew its license

There are a few other commands; but honestly I’ve never used them.

One more thing, you can run this on a jump box and remotely use the command too on a remote computer:

slmgr.vbs RemoteComputerName [username] [password] [switch commands noted above]

Cheers!

-Trevor 🙂