Q: My Terminal Server/Remote Desktop Session Host is sluggish and printer redirection isn’t functioning: What can I do?

 Editor's note: We've updated this FAQ to include a fix Microsoft has created. See the end of this FAQ for more details. 4-11-12

A: Over time, it’s possible for the terminal server to become bloated with inactive terminal server ports. They exist under the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\DeviceClasses\{28d78fad-5a12-11d1-ae5b-0000f803a8c2}\##?#Root#RDPBUS#0000#{28d78fad-5a12-11d1-ae5b-0000f803a8c2} key as child keys named #TSnnn (e.g., #TS001, etc.).

You can manually go through and delete them, but this is very tedious. A tool is now available at Codeplex,  which you can download and run to list all the inactive TS ports that can be deleted.

To list the inactive keys and to see which ones would be deleted, run the downloaded InactiveTSPortList.exe with the /r switch:

L:\Tools>InactiveTSPortList.exe /r

Then, to actually delete the keys, run the command again with /d instead of /r.

In the sample output below, I don't have any that need to be deleted as I already ran it once, but even on my home lab server I had 192 that it deleted on its first pass!

*-*-*-*-*-*-* InactiveTSPortList Version 1.0 *-*-*-*-*-*-*
*-*-*-*-*-* List and Delete Inactive TS Ports *-*-*-*-*-*

Running in read only mode.
Subkeys of HKEY_LOCAL_MACHINE\SYSTEM\CURRENTCONTROLSET\CONTROL\DeviceClasses\{28
d78fad-5a12-11d1-ae5b-0000f803a8c2}\##?#Root#RDPBUS#0000#{28d78fad-5a12-11d1-ae5
b-0000f803a8c2}
-----------------------------------------------
#TS001
#TS002
#TS003
#TS004
#TS005
#TS006
#TS007
............................................................................

Searching for Inactive TS Ports
1. #TS001 is Inactive TS Port
2. #TS002 is Inactive TS Port
3. #TS003 is Inactive TS Port
4. #TS004 is Inactive TS Port
5. #TS005 is Inactive TS Port
6. #TS006 is Inactive TS Port
7. #TS007 is Inactive TS Port

Press a key to exit.

Update: Microsoft also has a fix-it tool available to help resolve this problem now. It's available at the Microsoft support site. In addition, some additional information is available in the Microsoft blog post "Performance issues due to inactive terminal server ports."

 

 

 

Hide comments

Comments

  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
Publish