Fix The Remote Computer Disconnected the session because of an error in the Licensing protocol in Windows Vista. If you have this problem in Windows XP Pro / Windows XP, read this post : Fix MSLicensing Protocol Error in Windows XP.
The procedure to fix this issue is almost similar to the one described for fixing it on Windows XP, except for one extra step. Here’s the step-by-step process :
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
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.
5> After rebooting (ensure you are logged in as administrator), click on ‘Start‘ menu–> ‘Programs / All programs‘ –> Accessories
6> Right Click on Remote Desktop Connection and select the option “Run as Administrator“. This will recreate new Keys Hardware ID and Store under MSLicensing.
7> If you had renamed the keys and subkeys instead of deleting them, navigate to HKEY_LOCAL_MACHINE\Software\Microsoft\MSLicensing and you’ll notice the two newly folders created – HardwareID and Store. Delete the old HardwareID-temp and Store-temp and close the registry editor.
This solves the problem and you will be able to connect to remote servers using Remote Desktop Connection.
If you use a MAC, read this post: you were disconnected from the windows-based computer because of problems during the licensing protocol.
Not start from Run as, you need to Start->Run-> mstsc /admin
@Pavithra – If you are the admin, then you should get ‘Run as Administrator’ option. I wonder why you are not getting that. Let me see if I can find more info on this.
I tried all these
I suggest you temporary disable the antivirus programs on Windows 7 computers. If the issue persists, please open IE, click Tools->Manage Add-ons. Disable all add-ons that are from your security programs.
If the issue still occurs, follow the steps below to reset IE settings.
1. Click Start, please type “inetcpl.cpl” (without quotation marks) in the Start Search bar and press Enter to open the Internet options window.
2. Switch to the Advanced tab.
3. Click the “Reset Internet Explorer Settings” button.
4. Click Reset to confirm the operation.
5. Click Close when the resetting process has finished.
6. Uncheck the “Enable third-party browser extensions” option in the Settings box.
7. Click Apply, click OK.
If it does not work either, you may try to following method.
1. In Internet Explorer, click Internet Options on the Tools menu.
2. On the Security tab, click Trusted sites.
3. Click Sites.
4. In the Add this Web site to this zone box, type the address for the licensing server. If the server (or your computer) is not configured to use SSL, click to clear the Require server verification (https:) for all sites in this zone check box.
5. Click Add, and then click OK.
6. Click OK.
If the above suggestions do not help, I suggest you turn off Protected Mode in IE.
still no change.
no, i checked my computer settings, i am the admin. it is my personal laptop. still i am facing the trouble. tried creating a new mslicensing folder with and without subfolders, restarted multiple times….nothing helps. Please tell me if there is a solution.
@Pavithra – If you do not see the option “Run as Administrator”, then I guess administrator facilities have been turned off for you. You are most likely using your office laptop, where in such features will be disabled.
The only solution I can think about is to take help of your system administrator or any other person as such who is responsible for maintaining your laptop. Ask them to login with Administrator permissions, and then follow the instructions step-by-step. That’ll solve the problem.
I have a windows 7 and I tried all possible solution of removing MSlicensing folder. I do not have a copy of that folder. Tried disabling Anti-virus…etc…nothing works for my RDP file. Please guide me through to correct and connect to my Remote desktop. I do not see the option of Run as Administrator when I right click it.I am getting the error as “the remote computer disconnected the session due to an error in the licensing”
Please help me as I need to work on the remote server. I am not aware what the problem is.
@Brad – Thanks for your kind words 🙂
Thanks so much for this post. You made an admins day a little better :-).
Thanks very much for your post. I had been troubleshooting for awhile and found that all I had to do was run RDP client as administrator to create the MSLicensing keys. Kept thinking it was something on the server side but turned out to be my client.
windows 7 and runas was the solution.
Thank you very much. Congratulations.
@Nan – When you click on ‘Run as administrator’, please check if it’s creating MSLicensing key. If it’s not, then you can try creating it on your own, this way we can only hope it’ll work. We cannot be sure about it.
My vista is 32 bit. These are the steps I tried.
Deleted both the hardwareID and store entry under MSLicensing. Right clicked on remote desktop and selected run as administrator, still not connecting.
I do log into VPN first. This is so frustrating.
I am running VISTA home and I did try running as admin. I can’t check this on any of my Windows 7 computer, because this client doesn’t have their servers or VPN, not sure which, configured to let us use Windows 7 yet.
@Nan – Which version of Windows are you using ? Did you try to ‘Run’ it as an ‘Administrator’ ?
I have tried everything I can find and nothing is working. After I delete the registry entries and reboot, what should be there? I haven’t been able to work for a day because of this and my client isn’t any help.
Thanks, The one critical step I was missing was to “Run as Admin” so that my Win 7 RDC would rebuild the keys…
Again Thank You!
Thanks, “Run as Administrator” worked for my frustrated user. I was out of ideas. I used it on a Vista Home edition.
Thanks, Thanks, Thanks.
Thanks, “Run as Administrator” worked for two users of mine. I was out of ideas. Thanks, Thanks, Thanks.
I have this same problem… Windows7 64 bit cannot connect to a win 2000 terminal server.
@Karlo – when i try connecting to an older system from Vista it’s working fine for me. Right now I do not have a Win 7 machine to check if it is a generic problem or a one off. Meanwhile, let me try to find a solution for you from elsewhere. If you figure out any solution please update me with the same.
I have this problemn on a Win7 32 bit only contetting to a old Win200 Terminal Server.
I tryed to rebuild the registry keys, but it did not fix the prolblem.
Connect to RDP service on Win2003/Win2008 server is working fine.
salman chaudhry says
i did as u mentioned above, but problem have not fixed. please advised.
Mudassir Hussain says
thanks for the post. It really helped a lot. Keep up the good work going.
Thanks, this tip had been very helpful…
I have the same message but on a Mac using MS Remote Desktop for Mac- any idea how to correct?
@Tusik – Thanks for the update 🙂
Problem solved ! I used program called mstermlm.exe.
Guatam, thank You anyway !
@Tusik – Do you have teamviewer installed ? I can take a look at it.
I the administrator and I do run the command as administrator but still no luck.
@Tuisk – In Vista you need to explicitly execute commands as administrator. This is a new security feature that’s introduced.
I’m sorry but I still have the problem. The case is, that I don’t even have this folder called “MSLicensing” under the shown directory. I use Vista Hope Premium. Any suggestions?
@Said – Glad it was helpful.
Said Msamr says
Thanks for your tip. It did work and got me out of a sticky problem.