How can I view, who is currently connected to a server (Windows 2012) with a remote desktop client? I am myself connected to this server via RDP.
This question offers a solution to get IP addresses with established connections. I would be interested in a list of users or their sessions and when these sessions were active the last time.
You can type "Query User" into a command prompt on the remote machine to get a very quick look
Run the "qwinsta" command on the server, or with the /server:servername switch.
You can also reset an RDP session with the "rwinsta" command:
You can see in the Task manager users Tab
the
tsadmin.msc
command will give you a nice GUI with information and control over windows RDP sessionsFirst option - use command line to "query user /server:SERVERNAME" (or "quser.exe" - same thing). This shows User name, Session name, Session Id, Session state, Idle Time and Logon Time for all logged in users.
Second option option - use command line to "query session /server:SERVERNAME". This shows User name, Session name, Session ID and Session state. It shows all sessions, including disconnected ones, which might be useful.
Third option: install Microsoft Remote Desktop Connection Manager, configure your server(s), then right-click on the server to "list sessions". This shows Session ID, Session state, User domain/name, client machine name. Note that quser and qsession don't show client machine name, which might be useful to identify who is actually using the machine. RDCM doesn't show idle/logon time though, and it's quite outdated and glitchy.
Also important to note that all methods will fail to show active sessions if current user does not have admin rights on the queried remote server. So use "runas /u:DOMAIN\adminUser cmd.exe" to start adming console first.
https://pixelrobots.co.uk/2016/06/add-tsadmin-msc-back-to-windows/
If you can get those files, you can add tsadmin.msc back to Windows 10.