Windows‎ > ‎


windows remote desktop (terminal services)

Disconnect Users Disconnecting Terminal Server users (requires admins rights to do this, and assumes you have RPC access to the box):

1. From a command prompt, type in the following:

net use \\<machine IP>\ipc$
(for example: \\\ipc$)

You will get prompted for login credentials. Use you administrative credentials.

(NOTE: If you’d prefer, the commands in step 2 and 3 allow you to pass credentials as well, but I find this easier)

2. Type in the following to see the Terminal Server users:

qwinsta /server:<machine IP>
(for example qwinsta /server:

You will get output similar to the following:

console 0 Conn wdcon
sqltest 1 Disc rdpwd
jgithehu 2 Disc rdpwd

Note the numbers next to the names (sqltest is #1, jgithehu is #2). Both of these are disconnected, which means the session is left open.

3. Type the following to remove the user:

rwinsta <instance number> /server:<machine IP>
(for example, to kill jgithehu's session, we'd type in: rwinsta 2 /server:

4. Log in!