Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

You cannot completely disconnect a Terminal Server connection


View products that this article applies to.

Symptoms

After a Terminal Server client loses the connection to a Terminal Server, the session on the Terminal Server may not transition to a disconnected state, instead, it may remain active even though the client is physically disconnected from the Terminal Server. If the client logs back in to the same Terminal Server, a totally new session may be established, and the original session may still remain active.

↑ Back to the top


Cause

This issue can occur because Terminal Server implements a Keep Alive mechanism.

↑ Back to the top


Resolution

Important This section, method, or task contains steps that tell you how to modify the registry. However, serious problems might occur if you modify the registry incorrectly. Therefore, make sure that you follow these steps carefully. For added protection, back up the registry before you modify it. Then, you can restore the registry if a problem occurs. For more information about how to back up and restore the registry, click the following article number to view the article in the Microsoft Knowledge Base:
322756 How to back up and restore the registry in Windows

Windows NT 4.0 Terminal Server Edition

To work around this issue, follow these steps:
  1. Apply the latest service pack for Windows NT 4.0, Terminal Server Edition.
  2. Use Registry Editor to add a DWORD value, KeepAliveEnable, with a Positive numeric value of 1 (which represents 1 minute) to the following registry key:
    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server
  3. In the Terminal Server Connection Configuration tool, double-click rdp-tcp, and then click Advanced.
  4. On the On a broken or timed-out connection, <connect action> the session line, click to clear the inherit user config option. Click Disconnect on On a broken or timed-out connection, <connect action> the session, and then click OK.

Windows 2000 Server

To work around this issue, follow these steps:
  1. Use Registry Editor to add a DWORD value, KeepAliveEnable, with a positive numeric value of 1 (which represents Enable) to the following registry key:
    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server
  2. Open Terminal Services Configuration in Administrative Tools, double-click RDP-Tcp in the Connections folder, and then click the Sessions tab.
  3. Click to select Override user settings and make sure that Disconnect from session is selected and then click OK.

Windows XP and Windows Server 2003

To work around this issue, follow these steps:
  1. Click Start, click Run, type gpedit.msc, and then click OK.
  2. Expand Computer Configuration, expand Administrative Templates, expand Windows Components, and then click Terminal Services.
  3. In the right pane, double-click Keep-Alive Connections.
  4. Click Enabled, and then click OK.
  5. Close Group Policy Object Editor, click OK, and then quit Active Directory Users and Computers.

↑ Back to the top


Keywords: KB216783, kbui, kbprb, kbnetwork

↑ Back to the top

Article Info
Article ID : 216783
Revision : 10
Created on : 2/27/2007
Published on : 2/27/2007
Exists online : False
Views : 876