Troubleshoot the "Remote Desktop Disconnected" error
This article shows how to resolve the "Remote Desktop Disconnected" error when connecting to a Windows ECS instance by using Remote Desktop.
Problem description
When you try to connect to a Windows ECS instance by using Remote Desktop, the connection fails and you receive a "Remote Desktop Disconnected" error.
Cause
After you log on to the Windows instance by using VNC and check the system logs in Event Viewer, you find the following error message: "The Terminal Server security layer detected an error in the protocol stream and has disconnected the client". A corrupted Certificate subkey in the registry of the ECS instance causes this issue.
The Certificate subkey in the registry authenticates and encrypts data during Terminal Services communication. If this subkey is corrupted, the protocol component of Terminal Services detects an error and terminates the connection between the client and the ECS instance. The Certificate subkey can be corrupted for several reasons, such as installing or uninstalling certain system software or misconfiguring Terminal Services parameters.
Solution
The steps in this article are based on Windows Server 2008 R2. The procedure for other Windows versions is similar.
Connect to the Windows instance via VNC.
For more information, see Connect to an instance by using VNC.
Click Start > Run. In the Run dialog box, enter
regeditand click OK.In the Registry Editor window, navigate to the
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server\RCMpath. Right-click the Certificate key, select Delete, and then click Yes.Click Start > Administrative Tools > Remote Desktop Services, and then click Remote Desktop Session Host Configuration.
In the RD Session Host Configuration window, double-click RDP-Tcp. In the RDP-Tcp Properties dialog box, click the General tab. Set the Security Layer option to RDP Security Layer, and then click OK.
Restart the Windows instance to apply the new configuration.
Connect to the Windows instance via Remote Desktop and verify that you can log on.