At work we use sometimes a shared computer (Windows XP). Normally we access the software through Remote Desktop. The problem is that there is no way to tell if someone is already connected, if not running for office and asking everyone. Is there a way to know if someone is already connected with Remote Desktop, and what his user name without interrupting its connection?


qwinsta is your friend.

Open a command-line. Type qwinsta /server:machine-name.

It will tell who's logged to the machine. It'll tell you if it's local (console) or remotely (rdp-tcp#xxx).

  • I believe for this to work something called "RPC" has to be enabled. At least, I get the following errors: Error 1722 getting sessionnames Error [1722]:The RPC server is unavailable. – Mark Foskey May 30 '19 at 17:34

You can use the Terminal Services manager to connect to the Windows XP machine and review sessions. In this case, there should be two - a console session and the logged in user.

WMI should also expose this information for you, if you need this information available programmatically.

  • 1
    Since TSAdmin only comes preinstalled with Windows Server, command-line qwinsta can be used for the same purpose. However, both require Remote RPC to be enabled. – user1686 Oct 5 '11 at 11:37

Do you share the computer with a common user login? If not, and everyone is in the habit of logging off and not just disconnecting, you would have windows warn you, that you were about to disconnect so and so and thus you will know both if someone is on the machine, and also who they are, and you can cancel your connecting if someone is using it.

This relies upon everyone having their own credentials, (which is a good idea anyway) and having the good habit of logging off. Can you get them to all see the advantage of that?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.