Share This Post

"Query Session" and "Reset Session" for Windows Terminal Service

Windows Server 2003 you could use Terminal Services Manager to manage the terminal services sessions on remote computer. But this feather wasn’t available in Windows 2000. And sometime for whatever reason, you can’t get to the console even on Windows 2003.

Some of the Terminal Server Commands come to the rescue. You can use the “query session /server:<servername> to get a list of the sessions on the server:

C:\>query session /server:xyz
console 0 Conn wdcon
rdp-tcp 65536 Listen rdpwd
rdp-tcp#21 Administrator 1 Active rdpwd

Then you can use the “reset session” command to free up sessions.

C:\>reset session 2 /server:xyz

There is a KB article about this: KB30192

Share This Post

Ying Li obtained a Master degree of Medicine in China and worked in the medical field before he came to the states in 1996. He made the career switch from troubleshooting people to troubleshooting computers after he came to the states. Not entirely a surprise there, if you know that his second preference for college is Mathematics. Ying is two times Admin Framework MVP awardee (2007-2008).His previous employment experience in the US includes UUNET, MCI WorldCom. MMC (Marsh & McLennan Companies), Merrill Lynch. He is currently employed by Related Companies as a Senior Infrastructure Engineer. He is proficient in virtually all Microsoft products (Office/Back office). His craving for efficiency naturally leads him to scripting, automation and before you know it, PowerShell! He is currently a MCSE (NT4, 2000, 2003) and MCITP Server Administrator. Ying enjoys wines and love to travel. His non work related passion is to advocate Health Living!

Leave a Reply