Jump to content


Photo

How can I setup a KMS server ?


  • Please log in to reply
14 replies to this topic

#1 anyweb

anyweb

    Administrator

  • Root Admin
  • PipPipPip
  • 5,835 posts
  • Gender:Male
  • Location:Sweden
  • Interests:Deploying Operating systems and more with System Center Configuration Manager

Posted 20 January 2009 - 07:38 AM

KMS (Key Management Server)

What is a KMS server

KMS activates operating systems on your local network, eliminating the need for individual computers to connect to Microsoft. To do this, KMS uses a client/server method of implementation. KMS clients connect to a KMS server, called the KMS host, for activation. The KMS host resides on your local network.

Supported platforms

A KMS server can run on either windows 2008, Windows vista or Windows Server 2003 with SP1 and later, however installing it on Windows 2003 requires you to download the appropriate installation files for KMS v1.1.

Number of PC's required

To activate Windows Vista, you must have at least 25 computers running Windows Vista or Windows Server 2008 that are connected together; for Windows Server 2008, the minimum is 5 computers. Computers that are activated through KMS must be reactivated every six months by connecting to your organization's network.

KMS Setup

Note: Do all the commands below via a command prompt which has been opened with Administrative privileges.

Installing KMS Server:

Open C:\Windows\system32 and execute the following command
 

cscript c:\Windows\System32\slmgr.vbs /ipk xxxxx-xxxxx-xxxxx-xxxxx-xxxxx

Obvioulsy replace xxxxx with your key.

You should see the following:
 

Microsoft Windows Script Host Version 5.7
Copyright Microsoft Corporation. All rights reserved.
Installed product key xxxxx-xxxxx-xxxxx-xxxxx-xxxxx successfully.



How can I activate via Telephone (offline activation)

If activation for the KMS server is necessary then call Microsoft and follow the instructions.

Open C:\Windows\system32 and execute the following command



slui.exe 4

Then

* Show me other ways to activate
* use the automated phone system

And then call Microsoft and follow the instructions. After successful activation, click on close.

Then do as follows:
 

net stop slsvcnet start slsvc

You should see the following:
 

The Software Licensing service is stopping.
The Software Licensing service was stopped successfully.

The Software Licensing service is starting.
The Software Licensing service was started successfully.



Open the Firewall for KMS traffic

In Windows Firewall, click on Exceptions and allow the now listed Key Management Services, failure to do this step will mean that your KMS hosts can not talk to the KMS service and therefore will not activate.

KMS listens on port 1688, to change the port you must do as follows:



SLMgr.vbs /SPrt xxxx

where xxxx = the new port number

After you have entered this command you must restart the SLMgr service using:
 

net stop slsvc
net start slsvc

Test the KMS server configuration

The KMS server should publish its SRV records in your domain DNS, you should verify that these records exist.

Open C:\Windows\system32 and execute the following command



nslookup -type=srv _vlmcs._tcp

You should see output similar to the following:
 

C:\Users\Niall>nslookup -type=srv _vlmcs._tcp
Server: ad1.server2008.lab.local
Address: 192.168.3.1

_vlmcs._tcp.server2008.lab.local SRV service location:
priority = 0
weight = 0
port = 1688
svr hostname = kms03.server2008.lab.local
_vlmcs._tcp.server2008.lab.local SRV service location:
priority = 0
weight = 0
port = 1688
svr hostname = kms01server2008..lab.local
kms01.server2008.lab.local internet address = 192.168.3.3
kms02.server2008.lab.local internet address = 192.168.3.4



To manually activate a client over the Internet

Any client will automatically try to activate itself every 120 minutes by default, so there is no need to run the acivation command manually. However if you want to test or speed up the process then do as follows.

Open C:\Windows\system32 and execute the following command



cscript C:\Windows\system32\slmgr.vbs /ato

To change the 120 minutes setting, you must do as follows:
 

SLMgr.vbs /sai x

where x = the new interval in minutes

After you have entered this command you must restart the SLMgr service using:
 

net stop slsvcnet start slsvc

Query KMS server

To query the KMS server and see its status open a command prompt and execute the following command.



cscript slmgr.vbs /dli

You should see output similar to below:
 

Microsoft Windows Script Host Version 5.7
Copyright © Microsoft Corporation. All rights reserved.

Name: Windows Server ServerStandard edition
Description: Windows Operating System - Windows Server VOLUME_KMS_B channel
Partial Product Key: xxxxx
License Status: Licensed

Key Management Service is enabled on this machine
Current count: 2
Listening on Port: 1688
DNS publishing enabled
KMS priority: Normal

Key Management Service cumulative requests received from clients
Total requests received: 5
Failed requests received: 0
Requests with License Status Unlicensed: 0
Requests with License Status Licensed: 0
Requests with License Status Initial grace period: 5
Requests with License Status License expired or Hardware out of tolerance: 0

Requests with License Status Non-genuine grace period: 0
Requests with License Status Notification: 0



Microsoft Video showing KMS in action > http://www.microsoft...;DisplayLang=en



License States

A computer can be in one of 5 license states

Initial grace Period
This occurs after the computer is installed and can only last for up to 30 days, this can be reset twice.

Non-Genuine grace Period
This occurs after a computer is found to have a non-genuine or counterfeit Windows operating system installed. This state can last up to 30 days to give you time to reactivate using a genuine copy and License key.

Out-of-tolerance grace period
This can occur when either several hardware changes are made to the computer or when the KMS key has not contacted Microsoft for updates in 180 days. This state can last up to 30 days.

Licensed
This state occurs when everything is ok and the system is activated.

Unlicensed
This state occurs when the activation period has expired and nothing was done about it. The computer will stay in a limited access state until it has been activated.



Related Reading:-

Windows 7 Specific KMS info. For Windows 7 and Windows Server 2008 R2 KMS info please refer to this post.

Key Management Services (KMS) explained - http://www.virtuall....s-kms-explained

Which Key do I use, KMS, MAK, VLK ? IF you are unsure about which key to use for activation then take a look at this post on Technet, the list of keys is printed here


Microsoft MVP > Enterprise Client Management
My linkedin profile at > linkedin.com
Follow me on Twitter > ncbrady
Follow windowsnoob.com on Twitter > windowsnoob
My blog

#2 HellBird

HellBird

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 18 November 2009 - 07:27 PM

Hello,

I have two questions about KMS activation model.

If MAK key was entered into clients during installation, is KMS activation still possible? The problem is that we have entered MAK keys on all clients and now during activation process we receive error that maximum number of clients was already activated with MAK keys. If I understand how KMS works, at least 25 clients that are not activated must contact KMS host so that clients will get activated. What if we have already activated most of our clients with MAK, and we donít have enough clients to start KMS activation process?

Another question is about DNS records. We use internal AD domain domain.local. As I understand KMS DNS records will be added to internal DNS server. How can I enable clients that are not on LAN, to activate over the internet? We have a public domain and public DNS server, but domain is not the same as AD domain.

Thank you!

Best wishes,
Marko

#3 anyweb

anyweb

    Administrator

  • Root Admin
  • PipPipPip
  • 5,835 posts
  • Gender:Male
  • Location:Sweden
  • Interests:Deploying Operating systems and more with System Center Configuration Manager

Posted 10 December 2009 - 08:26 PM

hi Marko

sorry for the delay in replying i think the answer is yes but have you verified here on Microsofts Volume License site ?

in addition take a look at this resource on Technet it has videos explaining activation:

* Fundamentals of volume activation
* Activating Windows ® 7 with MAK
* Activating Windows ® 7 with KMS
* Understanding activation and validation in Windows ® 7 and Windows Server 2008 R2

cheers
niall
Microsoft MVP > Enterprise Client Management
My linkedin profile at > linkedin.com
Follow me on Twitter > ncbrady
Follow windowsnoob.com on Twitter > windowsnoob
My blog

#4 chiners_68

chiners_68

    Member

  • Members
  • PipPip
  • 29 posts

Posted 23 August 2010 - 12:51 PM

Current Scenario, I have around 2000 workstations. All are on XP SP3 bar a couple of techie machines which are on Windows 7 & are activated with our VLS MAK key. We are starting to deploy windows 7 now & need to install KMS server but i have a few questions.

Can I put KMS on Server 2008 R2 & Activate Windows 7 & office 2010 clients?

KMS works when you have more than 25 machines to activate. In the menatime while your working to 25 what do you do to activate the present windows 7 machines(say 5)?

do you get a key generated from the KMS server which you put into the sysprep for the windows 7 machines or do you leave the key field blank on client install?

Can I convert my MAK activated machines to KMS & how do you do this?

#5 anyweb

anyweb

    Administrator

  • Root Admin
  • PipPipPip
  • 5,835 posts
  • Gender:Male
  • Location:Sweden
  • Interests:Deploying Operating systems and more with System Center Configuration Manager

Posted 23 August 2010 - 01:46 PM

leave the windows 7 machines with a blank key until all 25 machines are reporting in, that's 25 including the windows server 2008 machines so should be easy to do,

do you think this will be a problem for you ?
Microsoft MVP > Enterprise Client Management
My linkedin profile at > linkedin.com
Follow me on Twitter > ncbrady
Follow windowsnoob.com on Twitter > windowsnoob
My blog

#6 chiners_68

chiners_68

    Member

  • Members
  • PipPip
  • 29 posts

Posted 23 August 2010 - 03:27 PM

im about to put in 80 new machines on a site & was going windows 7 so will be over the 25. Just wasnt sure what would happen to the windows 7 machines in the mean time that will be below 25 if they wont activate. I presume you have to activate them in a 3 day time period like the normal mAK activation.
I didnt want to put some machines out then they disable features because they havent activated as id not reached 25.

hope this makes sense ive got a stinking headache today.

#7 anyweb

anyweb

    Administrator

  • Root Admin
  • PipPipPip
  • 5,835 posts
  • Gender:Male
  • Location:Sweden
  • Interests:Deploying Operating systems and more with System Center Configuration Manager

Posted 23 August 2010 - 05:06 PM

they will be in a state called:

Initial grace Period
This occurs after the computer is installed and can only last for up to 30 days, this can be reset twice.


until the magical number 25 is reached or until their Activation Grace Period is reached,
to find out when that date is do this:

slmgr -xpr

That will Display the date when the current KMS based activation will expire

you'll find lots of info about KMS and MAK key's here http://technet.micro...y/dd981009.aspx
Microsoft MVP > Enterprise Client Management
My linkedin profile at > linkedin.com
Follow me on Twitter > ncbrady
Follow windowsnoob.com on Twitter > windowsnoob
My blog

#8 chiners_68

chiners_68

    Member

  • Members
  • PipPip
  • 29 posts

Posted 24 August 2010 - 08:04 AM

Thanks Niall.

#9 chiners_68

chiners_68

    Member

  • Members
  • PipPip
  • 29 posts

Posted 24 August 2010 - 09:31 AM

Hi Niall, Tried running cscript c:\Windows\System32\slmgr.vbs /ipk xxxxx-xxxxx-xxxxx-xxxxx-xxxxx with my windows 7 KMS key from mvlsc bit I gett error 0xc004f015.

Ive read around & one forun sugestion was you only use the windows 7 kms key if your installing KMS on a windows 7 box? is this correct & do I just need to install the 2008R2 KMS key as my server is that? I only want to activate win7/office 2010 clients for now though.

#10 anyweb

anyweb

    Administrator

  • Root Admin
  • PipPipPip
  • 5,835 posts
  • Gender:Male
  • Location:Sweden
  • Interests:Deploying Operating systems and more with System Center Configuration Manager

Posted 24 August 2010 - 11:56 AM

you should be using the KMS key only on the server, are you doing that ?
Microsoft MVP > Enterprise Client Management
My linkedin profile at > linkedin.com
Follow me on Twitter > ncbrady
Follow windowsnoob.com on Twitter > windowsnoob
My blog

#11 Gogan

Gogan

    Newbie

  • Members
  • Pip
  • 1 posts
  • Gender:Male

Posted 08 May 2011 - 05:06 AM

Hi :
First of all, This site is very informative. Thanks.


I have one question that I have KMS on WIndows Server 2008 R2 and I am using this for activating WIndows Server 2008 R2 machine, now my company has bought the windows 7 prof and Office 2010 prof licenses, Can I use the same KMS server for activating these two , And How to add these product for activation in the existing KMS. Thanks in advance.

#12 Vicmon

Vicmon

    Member

  • Members
  • PipPip
  • 13 posts

Posted 09 May 2011 - 03:25 PM

Gogan,

If you have installed VAMT 2 onto the server running KMS, you can add the product keys for Win7 and Office 2010 under the 'Product Keys' listing in the VAMT console.

Hope this helps. :)

Attached File  New Bitmap Image.bmp   699.93KB   1471 downloads

Hi :
First of all, This site is very informative. Thanks.


I have one question that I have KMS on WIndows Server 2008 R2 and I am using this for activating WIndows Server 2008 R2 machine, now my company has bought the windows 7 prof and Office 2010 prof licenses, Can I use the same KMS server for activating these two , And How to add these product for activation in the existing KMS. Thanks in advance.



#13 DAdams982

DAdams982

    Newbie

  • Members
  • Pip
  • 6 posts

Posted 10 June 2011 - 05:26 PM

Gogan,

If you have installed VAMT 2 onto the server running KMS, you can add the product keys for Win7 and Office 2010 under the 'Product Keys' listing in the VAMT console.

Hope this helps. :)

Attached File  New Bitmap Image.bmp   699.93KB   1471 downloads


Hopefully I get this right. I should first run the how to attatched at the top of this thread, then I can use VAMT to add keys?

How difficult is this with a closed network? I know KMS try's to phone home every so often, is the a problem with KMS?

#14 Don - tesgroup

Don - tesgroup

    Newbie

  • Members
  • Pip
  • 2 posts
  • Gender:Male
  • Location:Melbourne, Australia

Posted 02 July 2011 - 08:48 PM

Hopefully I get this right. I should first run the how to attatched at the top of this thread, then I can use VAMT to add keys?

How difficult is this with a closed network? I know KMS try's to phone home every so often, is the a problem with KMS?


KMS-clients phone home to the KMS-Host. KMS-Hosts do not phone home to MS.

#15 kra66

kra66

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 08 July 2011 - 11:21 AM

So far this is some good info. But I have a few questions as well.

We have converted 2000+ systems to Windows 7 already using a KMS license. But we have been informed that the server running the KMS Host will be de-comissioned. So we need to move the the KMS Host to a new server. How should we go about doing this?

Microsoft has just issued us a new Windows 7 KMS license key. Should we use this new key or stick with the old key?

When moving to the new KMS Host, will it still take adding 25 "new" systems in order for the license to be come active? Or will our exist Windows 7 system report in and the key will activate with in minutes?

Thanks alot.

KRA




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

Locations of visitors to this page