• Skip to main content
  • Skip to primary sidebar
  • Advertise

Computer Tips And Tricks, Gadgets, How-To, Life - 2.0 Style

Get latest technology updates and computer tips and tricks.

How to fix – The Remote Computer Disconnected the session because of an error in the Licensing protocol

April 8, 2009 by Gautam

Today, one of my client had problem while he was trying to connect to a remote computer to work. The remote desktop on his Windows XP (Related Post : If you have MSLicensing Problem on Windows Vista, then check this post.) was running fine, but now he was getting this error:

“The remote computer disconnected the session because of an error in the licensing protocol. Please try connecting to the remote computer again or contact your server administrator.”

When I looked up in the knowledge base, this is what Microsoft had to say :

“Cause: The licensing protocol handles the communication of licensing information between your computer and the remote computer. If there is an error in the licensing protocol, your computer cannot be connected to the remote computer.

Solution: Try connecting to the remote computer again. If you continue to receive this error message, contact the server administrator”

Well here’s the solution to fix this problem:

This actually is a registry fix. You’ll be prompted to delete a few keys and subkeys and hence it’s better if you take a back up of your registry manually, so that you can restore it if something goes wrong during the process.

If you do not know how to take back up of your registry manually follow this tutorial : Tutorial to to back up the registry in Windows Vista or in Windows XP.

Once you have taken the back up,

1> Click on Start Menu –> Go to Run Command box –> Type regedit –> This opens the registry Editor.

2> Navigate to HKEY_LOCAL_MACHINE\Software\Microsoft\MSLicensing

How to fix -  The Remote Computer Disconnected the session because of an error in the Licensing protocol

3> Delete all the keys under MSLicensing : both HardwareID and Store keys and their subkeys. If you are not sure how to delete the key and its subkeys, just rename them as follows : HardwareID to HardwareID-temp and Store to Store-temp.

4> Reboot the system. Rebooting will create new Keys under HardwareID and Store and this will fix your problems.

5> If you had renamed the keys and subkeys instead of deleting them, navigate to HKEY_LOCAL_MACHINE\Software\Microsoft\MSLicensing and you’ll the two newly created folders – HardwareID and Store. Delete the old HardwareID-temp and Store-temp and close the registry editor.

That’s it !

Recommended reading: Registry tweak to improve performance of Windows XP

Filed Under: How To's, Microsoft Windows Tips And Tricks

Reader Interactions

Comments

  1. Dualeh says

    November 9, 2011 at 6:17 pm

    Hi all,

    i am having problem one of my server, i cannot connect as a remote, this happen since yesterday, beofre yesterday it was fine working, usually i use vista machine and it was working more 3 years. this is the message “protocol error this session will disconnect try later” can some help me.

    many thanks

  2. Peter says

    November 7, 2011 at 9:00 pm

    This still doesn’t work. I have deleted the keys and followed the procedure through on two different systems both with the same emssage one it worked fine the other it didn’t . Both are running Windows XP pro and both have up to date SP’s.

  3. Rogalik says

    July 13, 2011 at 6:29 pm

    After the MSLicensing removal you must start mstsc as the administrator for the reconstruction of keys.

  4. peter majors says

    July 7, 2011 at 8:52 pm

    No luck on this, followed instructions exactly. Win 7 OS

  5. Ken says

    February 5, 2011 at 4:50 am

    Hi,

    I deleted the HardwareID and Store folder. However, only the HardwareID is created after I restart the system. I still have the same problem. Can you help? thanks.

    Ken

  6. Gautam says

    February 4, 2011 at 8:10 am

    @Ben – The easiest way to sort this problem is:
    1> Take a back up of your registry file. If you do not know how, please Google “How to take back up of Registry file”.
    2> When I said “Delete the MSLicensing Key”, I meant the whole folder itself, rather the complete key=value pair. Once you have deleted it, follow the instructions step by step, and that should easily solve your problem.

    If in case you still face problems, especially because of registry key, the you can overwrite the new registry setting with your old one, since you would have taken a backup.

    Cheers,

  7. ben says

    February 4, 2011 at 4:47 am

    I just wanted to make sure when you said “delete the MSLicensing key”, you meant the whole folder or just the registry file under MSLicensing? My problem is I could not delete that registry file under MSLicensing and I have 2 folders under MSLicensing, they are hardwareID & Store. I tried to delete the registry file only, but it said :unable to delete all specified values” Anyone got clue? Thanks in advance!

  8. Art says

    January 12, 2011 at 1:45 am

    This worked like a champ. Thanks for the info. I am trying to connect using Windows 7 home laptop to our office server.

  9. Matt says

    January 6, 2011 at 6:00 am

    Fire :
    In Windows 7 it’s really important that you start the remote desktop session after deleting the registry key “as Administrator”. If not, the registry key wouldn’t be created correctly.

    This was the key for me. Some posts above suggest running IE as adminstrator, but it is the “Remote Desktop Connection” program that needs to be run as Administrator in order for the registry keys to be created after deleting them.

  10. Robert says

    January 5, 2011 at 1:24 am

    This all still begs the question of why doesn’t Microsoft fix this problem???
    It has been a problem since 2000. I have 125 servers in the fileld around 8000 workstations… and all have this problem. All the way to 2008R2. They say its a problem with the network but that can’t be true on all the networks??? Local, Remote, 1 server 1 workstation with cross over cable. The protocol is the problem. My customers are mad at me for this problem. What should I tell them? OY!!!!

    Microsoft needs to address this issue!

  11. valboy says

    December 31, 2010 at 10:51 pm

    Thanks! This fixed the error on my Vista Home Premium!

    I compared the old registry values to the recreated values and as far as I can see, only the ClientHWID value has changed. Could it be that the Terminal Server was restarted and in the process my laptop’s ID was lost? So logging remotely with an invalid ClientHWID will produce an error, but if the registry has no key for ClientHWID then it will be recreated propertly? BTW, Fred Schneider’s tip did not work for me (IE8).

    http://www.hardwareanalysis.com/content/topic/29453/
    http://support.microsoft.com/kb/2021885

    Keywords to search: ClientHWID, TS CAL

    Happy New Year y’all 🙂

  12. Fred Schneider says

    December 26, 2010 at 12:37 am

    This is an odd error that seems to be croping up all over. I was having a major headache using RDP to log into a server in my forrest. Funny thing I did to fix this was when I opened IE to type the address to my remote login, I just ran IE as administrator. It worked without me editing the registry or anything else. Worked for both my Win7 and my Vista computers.

  13. ed says

    December 23, 2010 at 1:57 am

    copying the MSLicensing registry key from another system and imported it, works like charm

  14. Will Howard says

    December 20, 2010 at 8:01 pm

    Swapnil

    Easy fix – see post above.

    Here’s a recap of what you need to do:
    1. Run REGEDIT
    2. Locate HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSLicensing
    3. Delete the MSLicensing key
    a. Make sure this is the only thing selected.
    b. If in doubt, you can always export the key out to a file as a backup before deletion
    4. Re-run Remote Desktop Connection
    a. If running Windows 7 or Vista, you must right click on the Remote Desktop Connection shortcut and choose “Run as Administrator”
    b. Windows XP – simply run Remote Desktop Connection
    5. The software should regenerate the keys and you will see the login screen

  15. Hassan says

    December 20, 2010 at 6:00 pm

    Hi, I hade the same problem: This solv my problem.
    Befor you do this make sure u have deleted supfolders to ” KEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSLicensing”
    Start run and type MSTSC when you cee the remote desktop mangement wright click and Run as administrator.
    This worked for me.
    Regards,
    Hassan

  16. Gautam says

    December 20, 2010 at 12:40 am

    @Swapnil – Which OS are you using ?

  17. Swapnil says

    December 19, 2010 at 11:26 am

    Hi,

    This is Swapnil. when i am trying to do remote connection I am getting following erro.

    The remote computer disconnected the session because of an error in the licensing protocol. Please try connecting to the remote computer again or contact your server administrator.

    Please if u can tell m the right solution.

    regards,

    swapnil

  18. Tricky says

    November 24, 2010 at 8:27 pm

    I had the same RDP problem but on a Windows 7 machine.

    I right clicked on the RDP icon and selected Run as Administrator and it fixed the problem for all users on that PC.

    Thanks for the advice.

  19. Fire says

    November 16, 2010 at 7:18 pm

    In Windows 7 it’s really important that you start the remote desktop session after deleting the registry key “as Administrator”. If not, the registry key wouldn’t be created correctly.

  20. Binh says

    October 11, 2010 at 9:30 am

    Thank you for this.
    I have the same problem but on a Windows 7 machine.
    Deleting the registry key removed that error message but I got another one which shows up: “The remote computer disconnected the session because of an error in the licensing protocol”

    All I had to do then is right click RDP and select “Run as Administrator” which then created that registry key that was removed.

  21. Wole says

    September 6, 2010 at 2:17 pm

    Thanks guys..copying MSLicensing registry key from a PC known to be working to the PC with the problemw saved the day.

  22. mayur says

    August 23, 2010 at 10:00 am

    Thanks that help.

  23. Daniel says

    August 19, 2010 at 3:21 am

    Using Windows 7: I bought a new notebook, the first time I tried to connect to remote desktop the error message came up. Followed advice from above [right-clicked Internet Explorer icon, and clicked “Run as administrator”]. Now connects fine. Thank you!

  24. Carino says

    August 9, 2010 at 4:14 pm

    please help me…. my one computer is remove from the server i can’t manage the time for it……how can i connect again to that computer.. please help….

  25. Carino says

    August 9, 2010 at 3:33 pm

    what pc will where i edit.. in the server or on the pc who have problem?

  26. Liger says

    August 4, 2010 at 12:02 am

    @Joe
    I had this problem on windows 7 and I run as admin and recreated the deleted keys.

  27. Joe says

    July 7, 2010 at 6:31 pm

    Hi, had this problem overnight on Windows 7, my user account is an admin but the recreation of keys wasn’t working. After reading the comments here I forced the run as admin option by right clicking, didn’t realise it was different from logging in as admin and running the program… This recreated the deleted reg keys and the access to my RDP sesssions was restored.

  28. Mike says

    June 11, 2010 at 3:01 pm

    Using Windows 7: your suggestions worked for me. I deleted the registry keys; rebooted the computer; right-clicked Internet Explorer icon, and clicked “Run as administator”. Thank you!

  29. DukeMini says

    May 26, 2010 at 9:45 pm

    Tried it on different clients. Win XP Prof. and Win 7 Prof. Always as an administrator. But it won’t work for me. 🙁

  30. Charles says

    May 21, 2010 at 4:59 am

    great! It works for me

  31. Spaski says

    May 20, 2010 at 3:20 pm

    Thanks that helped!!!!!

  32. Arassen says

    May 10, 2010 at 4:25 pm

    thanks for the post. it works fine for me. i renamed the licenses and tried reconnecting to my server it worked.
    regards
    arasssen

  33. JT says

    April 29, 2010 at 10:00 am

    thanks all,
    these solved the problem I faced. been spending many hours on the server-side tring to fix the problem.

  34. Panoone says

    April 27, 2010 at 6:48 am

    @Paul

    Ah, you legend. Just what I was looking for. Was going crazy looking at all the possible server-side issues. This worked for me.

  35. Paul says

    April 22, 2010 at 12:26 am

    @Compari: a Mac fix:

    I was getting this error using RDC on the Mac too, but a colleague found this article from Microsoft: http://support.microsoft.com/kb/187614

    The good stuff for Mac is about half-way down the article:

    “The RDP client for Macintosh stores the license in a file on the local computer in the folder hierarchy under /users/Shared/Microsoft/RDC Crucial Server Information/. To clean the Macintosh client’s license cache, delete the contents of this folder. The client will try to obtain a new license from the server the next time that it connects.”

    Just worked for me…Hope this helps some

  36. Santosh says

    April 20, 2010 at 11:13 am

    it doesn’t work.I had followed all steps but no result

  37. Measureman says

    March 16, 2010 at 8:25 pm

    This works for Win7: The first time you try to connect to a RWW site, run Internet Explorer as Administrator (Right-click the IE icon, select Run as administrator). Now the registry settings are renewed.
    Note: You only need to this the first time.

  38. Gautam says

    February 28, 2010 at 10:33 am

    @Haydee – If you’ve followed all steps mentioned in the post, you should have a new MSLicensing key created when you restart your system.

    What exactly is the problem?

  39. haydee says

    February 28, 2010 at 9:09 am

    I deleted my MSlicensing from my laptop computer in error…please help I have windows XP and have been trying to get this back, I need it for work…

  40. Gautam says

    February 17, 2010 at 2:10 pm

    @Compari – I need to look into this one. Will get back To you soon. Best,

  41. Compari says

    February 17, 2010 at 10:53 am

    I am running MAC PRO and the server is Windows 2000. I am having the same error in Licensing protocol. Someone told me to delete the RDC files on my MAC and that would solve the problem. I don’t know where Microsoft RDC files are on the MAC. Can you help?
    please note all other Windows workstations do not get the licensing protocol error from the Server. Only my MAC does.

    Thanks

  42. narayanan says

    February 4, 2010 at 3:18 pm

    Windows 7 is my system. Target system is windows 2008 server
    i tried from XP system also, but the same message..

  43. Gautam says

    February 4, 2010 at 12:10 pm

    @Narayanan – Whats the environment you are working in ?

  44. narayanan says

    February 4, 2010 at 11:29 am

    hi, am also facing similar problem. But after doin the above steps still getting same error. Actually we have hosted 2 server in data centre. and both we access thru remote desktop, while one server we were able to connect thru remote desktop, another server we getting that error.
    pls help

  45. Gautam says

    January 14, 2010 at 2:15 am

    @Chass – Sounds good. I’ll leave this comment on so that it can help others ! Thanks .

  46. Chass says

    January 14, 2010 at 2:12 am

    I had tried right clicking but there is no option for “Run as administrator” when you are logged in as administrator. I did find a solution though. This is pirated from another website. He said there are 3 solutions. It took the second one for me and I went ahead and changed the permissions too.

    1) Right click the icon and click “Run as Administrator”
    2) In the search menu on the Start menu type “mstsc” (no quotes) and then instead of hitting Enter press Ctrl+Shift+Enter to run mstsc.exe (Remote Desktop) as an administrator.
    3) The less-hassel way it to open regedit, navigate to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSLicensing, and right-click and change the permissions so all users have full control of that key.

  47. Gautam says

    January 14, 2010 at 2:06 am

    Chass, though you’ve logged in as administrator you need to manually run each command as an administrator. While creating the license keys right click and you’ll find the option run as administrator and this will create the licensing keys. If the problem still persists, let me know so that I can send the exact procedure.

    Best

  48. Chass says

    January 14, 2010 at 12:41 am

    I’m running Vista Home trying to fix the same problem with a users computer. I’m logged on as an administrator. I’ve deleted the keys inside of MsLicensing and rebooted. I get the same error message as before. It did not recreate the licensing keys. So I exported them from an XP machine but it won’t import the keys. I don’t have any other Vista machines in the building to export the key from. Any suggestions?

    Chass

  49. Gautam says

    November 12, 2009 at 2:35 pm

    @Ramu – welcome ramu

  50. ramu says

    November 12, 2009 at 11:14 am

    thank u bozz

  51. Gautam says

    October 30, 2009 at 5:11 pm

    @Matt – Did you try running it as the administrator ? While running, right click and select the option ‘Run as adminimstrator’. That should help if you are on Vista. If you still have problems let me know.

  52. Matt says

    October 29, 2009 at 9:32 pm

    Got same problem. Removed MSLicensing key, did not recreate itself. Imported from a working PC – didn’t work either.

    Running Vista SP2.

  53. Spazz says

    October 12, 2009 at 12:17 pm

    I removed the key because of an error that the licensing could not be renewed. Then I got this error “Licencing protocol error”. Now there is no key in the registry to delete. Do you have any further help?

  54. luv2bike2 says

    September 15, 2009 at 8:03 pm

    the deleting of the registry key/subkeys did not work so I copied the MSLicensing registry key from my computer to the one that was having a problem, that solution worked for me as well.

  55. Gautam H N says

    May 4, 2009 at 7:36 pm

    @ Softwaresnhard – I don’t see a reason why this would not work 🙁 .. may be there are situations when it doesn’t. Thanks for informing.

  56. Softwaresnhard says

    May 4, 2009 at 1:37 pm

    Hi, I tried this method before and it didnot work out for me, at last i end up copying the MSLicensing registry key from another system and imported it, it worked…

Trackbacks

  1. A Free Tool For Administrators To Block Application On Systems On Network | Computer Tips And Tricks, Gadgets, How-To, Life - 2.0 Style says:
    April 14, 2009 at 3:00 am

    […] reading : Licensing Protocol In Windows Vista Share and […]

  2. How To Connect Remote Desktop Client For Microsoft Windows Server From A MacBook Pro / Mac OS X ? | Computer Tips And Tricks, Gadgets, How-To, Life - 2.0 Style says:
    April 11, 2009 at 3:46 am

    […] But my client was getting a generic error : “You were disconnected from the Windows-based computer because of problems during the licensing protocol”. We’ve already discussed one of the regular problem: “The Remote Computer Disconnected the session because of an error in the Licensing protocol“. […]

Primary Sidebar

Copyright © 2023 · Magazine Pro on Genesis Framework · WordPress · Log in