The remote session was disconnected

In this article, we’ll look at several common concerns regarded RDS licensing, as soon as RDP clients cannot connect to Windows Server via the Remote Deskpeak Services Host function installed.

You watching: The remote session was disconnected

Licensing errors once connecting RDP clients to an RDS host might show up if:

The RDS licensing server has actually run out of accessible CALs;The RDP client tries to affix via an expired temporary RDS license;

Remote session was dislinked bereason there are no Remote Deskheight client access licenses easily accessible for this computer

First, let’s look at an error pertained to clients gaining RDS CALs from the license server.

Remote session was dislinked bereason tbelow are no Remote Desktop client access licenses obtainable for this computer. Please call the server administrator.


Connect to the RDSH server in governmental mode (mstsc.exe /admin) and also run the RD Licensing Diagnoser tools. If you have actually everything configured properly, you have to watch the name of the RDS licensing server, and the kind of license (Per User/Per Device).


Connect to the RDS license server using the RD Licensing Manager console (licmgr.exe) and also inspect that you have actually easily accessible free licenses of the compelled type (Per User or Per Device). If you run out of free RDS CALs, you need to purchase a new CAL load, wait for someone to release the license, or revoke unoffered licenses directly from the console (right click on the computer/user and also choose Revoke License).


In this example, you have the right to check out that there are totally free RDS CALs, and they are issued to users (Issued = 44).

Hint. If your RDSH server is deployed in a workgroup (not in an AD domain), then you cannot use Per User RDS licenses on it. When linked, your individuals will always receive a momentary local Per Device license.

Many most likely, in this case the client computer system is trying to affix to your RDSH server with an expired short-term RDP license (if your RDS license server was unaccessible when the client initially linked, the client was issued a short-lived RDP license for 180 days). In this instance, you must recollection this expired license in the regisattempt on the client device.

Do the adhering to on the client computer system (Windows 10 in this example):

Start the Regisattempt Editor (regmodify.exe);Connect to your RDS server. In this instance, the MSLicensing reg essential will be immediately re-produced, and also the computer system will certainly receive a brand-new RDP license.
If you did not run mstsc.exe with administrator pergoals, then an error will show up for any RDP connection:

The remote computer system disconnected the session bereason of an error in the licensing protocol. Please attempt connecting to the remote computer system aobtain or contact your server administrator.

The remote session was disconnected because tbelow are no Remote Deskpeak License Servers accessible to administer a license

One of the customer has encountered a difficulty with the deployed farm of RDS servers on Windows Server 2012 R2. For some factor, the RDS server has quit issuing terminal licenses to users, though the license server role had actually been mounted and also configured, and RDP CALs had actually been set off.

When a user tries to affix to the terminal server via RDP, the following error appears:

The remote session was disconnected bereason tright here are no Remote Deskheight License Servers obtainable to provide a license. Please call the server administrator.


Connect to the server consingle in administrative mode (mstsc /admin). Open the Server Manager, and go to the RDS settings (Remote Deskoptimal Services -> Deployment Overview -> Tasks -> Edit Deployment Properties). Make certain that the correct Remote Deskheight license server and RDS CAL type (Per Device or Per User) are mentioned in the RDSH configuration.


You have the right to likewise examine the RDS licensing server settings by means of PowerShell:



As you have the right to view, LicenseServer is stated in the configuration, and also the PerUser licensing form is supplied.

See more: Strange Sound Played At Windows Startup And " Name Not Available Volume Mixer

Check that the following ports are not blocked by firewall surfaces when accessing from RDSH host to RDS LicenseingServer: TCP 135, UDP 137, UDP 138, TCP 139, TCP 445, TCP 49152–65535 (RPC range). If the RDS License server is not obtainable, the License Diagnoser will certainly display an error:

License server rdslic_hostname is not easily accessible. This might be led to by netjob-related connectivity troubles, the Remote Deskheight Licensing business is stopped on the license server, or RD Licensing isn"t available.

Recollection 120 Days RDS Grace Period (L$RTMTIMEBOMB)

Take a cshed look at the occasions in the Event Viewer on the RDS host. Perhaps there is an error like this:

EventID: 1128Source: TerminalServices-RemoteConnectionManagerThe RD Licensing grace period has actually expired and also the business has actually not registered through a license server with set up licenses. A RD Licensing server is forced for constant operation. A Remote Deskheight Session Host server deserve to operate without a license server for 120 days after initial begin up.


The RD License Diagnoser will certainly the majority of likely also display screen an error:

The grace period for the Remote Deskheight Session Host server has expired, but the RD Session Host server hasn"t been configured via any license servers. Connections to the RD Session Host server will certainly be denied unmuch less a license server is configured for the RD Session Host server.This indicates that your grace duration for the RDSH server has actually expired, and also you should extend the grace mode, or activate the organize on a RDS license server.

The RDS grace duration allows you to use Remote Desktop Services on Windows Server for cost-free for 120 days. Many likely, when logging into RDSH as administrator, you observed an error:

Licensing mode for the Remote Deskheight Session Host is not configured.Remote Deskheight Service will soptimal working in 86 days.
The variety of days before the end of the RDS Grace Period deserve to be discovered from the elevated command prompt:

wmic /namespace:\rootCIMV2TerminalServices PATH Win32_TerminalServiceSetting WHERE (__CLASS !="") CALL GetGracePeriodDays


Note that DaysLeft = 0. This suggests that the Grace Period has expired on this RDSH host.

To extend the grace period in RDS, you have to remove the regisattempt parameter on the server, which determines the grace period licensing time. The day that determines the RDS grace period for the server is stored in the reg_binary registry parameter L$RTMTIMEBOMB (rather a funny name –TIME BOMB….) located in the following registry key:

HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlTerminal ServerRCMGracePeriod


You have to rerelocate the L$RTMTIMEBOMB parameter from the regisattempt. However, the administrator does not have enough pergoals to perform this.

Unable to delete all specified worths.


To remove this regisattempt parameter, you need to open up the parent essential pergoals and give your account the privileges of the crucial owner. Then set the Full Control permissions for Administrators group (I won’t describe the process in detail).


Now, right-click L$RTMTIMEBOMB parameter and delete it.


Restart your RDSH server, and connect to it using RDP client. Make certain that the RDS CAL has actually been issued efficiently making use of the Remote Desktop Licensing Manager.


If the RDS CAL is not obtained, examine if there is an occasion in the Event Viewer:

Event ID: 1130Source: TerminalServices-RemoteConnectionManager The Remote Desktop Session Host server does not have a Remote Desktop license server stated. To specify a license server for the Remote Desktop Session Host server, usage the Remote Deskoptimal Session Host Configuration tool.

See more: Successfully Scanned Windows Installations 0 Error!, Fix: Total Identified Windows Installations: 0


Using this PowerCovering command, make certain if the RDS licensing server is set:

$obj = gwmi -namespace "Root/CIMV2/TerminalServices" Win32_TerminalServiceSetting$obj.GetSpecifiedLicenseServerList()


As you have the right to check out, the RDS licensing server is not collection (SpecifiedLSList is empty). Force collection the RD licensing server through the adhering to command:

$obj = gwmi -nameroom "Root/CIMV2/TerminalServices" Win32_TerminalServiceSetting$obj.SetSpecifiedLicenseServerList("")

You can additionally set the license server name and license kind using the Group Policy GPO. If you are making use of Local GPO, run the gpedit.msc and go to area Computer Configuration -> Administrative Templates -> Windows Contents -> Remote Desktop Services -> Remote Deskoptimal Session Host -> Licensing. Set the complying with options:Use the specified Remote Deskheight license serversSet the Remote licensing mode


The RDS organize will certainly now have the ability to acquire licenses from the RDS Licensing server and concern them to your RDP customers.