In this Post i am going to show you How to Query and Rest the Terminal Sessions Remotely.
You must be aware that only two users are allowed for Remote Administration, if third one tries to login on the same Machine he/she will receive an error message "Exceeded the number of terminal connections". This may happen if two people are legitimately using the servers or if someone forgot to log off. Now think if your servers are far away from you and you are facing this problem :(
Now no worries, here you will find how to reset the Terminal Sessions Remotely :)
Note:- To use these commands you must have the admin credentials and same username/password that is on the Remote Machine which you want to Reset.
For example, let's say that I can't gain access to a server (with ip:- 192.168.1.10) using Terminal Services because both sessions are used up. I can use another server to check the status of the first one. As long as the logged in user has administrative rights on the non-accessible machine I would run this:
qwinsta /server:192.168.1.10
Where 192.168.1.10 is the IP address or name of the non-accessible machine.
This will display something like this:
Now I know that Naik and Sabu are the two that are logged in. Since Sabu left the office 1 hour ago I know that he forgot to log off and Naik has done same thing forgot to log off. Now i need to reset one of the session then i will be able to login
To disconnect Sabu's session I would type this:
rwinsta /server:192.168.1.10 3
Notice the 3 which is the session ID I found from using qwinsta above.
The qwinsta and qwinsta stands for
qwinsta = Query WINdows STAtion
rwinsta = Reset WINdows STAtion
Microsoft has replaced these two tools with Query but since qwinsta and rwinsta is fully compatible with W2K WinXP and W2K3.
So you can use below Commands as well
To displays information about sessions on a remote terminal server.
query session /server:192.168.1.10 (Same as qwinsta)
Note:- 192.168.1.10 is a remote machine ip.
To reset (delete) a session on a terminal server.
reset session /server:192.168.1.10 3 (Same as rwinsta)
Note:- 3 is a session ID
You must be aware that only two users are allowed for Remote Administration, if third one tries to login on the same Machine he/she will receive an error message "Exceeded the number of terminal connections". This may happen if two people are legitimately using the servers or if someone forgot to log off. Now think if your servers are far away from you and you are facing this problem :(
Now no worries, here you will find how to reset the Terminal Sessions Remotely :)
Note:- To use these commands you must have the admin credentials and same username/password that is on the Remote Machine which you want to Reset.
For example, let's say that I can't gain access to a server (with ip:- 192.168.1.10) using Terminal Services because both sessions are used up. I can use another server to check the status of the first one. As long as the logged in user has administrative rights on the non-accessible machine I would run this:
qwinsta /server:192.168.1.10
Where 192.168.1.10 is the IP address or name of the non-accessible machine.
This will display something like this:
Now I know that Naik and Sabu are the two that are logged in. Since Sabu left the office 1 hour ago I know that he forgot to log off and Naik has done same thing forgot to log off. Now i need to reset one of the session then i will be able to login
To disconnect Sabu's session I would type this:
rwinsta /server:192.168.1.10 3
Notice the 3 which is the session ID I found from using qwinsta above.
The qwinsta and qwinsta stands for
qwinsta = Query WINdows STAtion
rwinsta = Reset WINdows STAtion
Microsoft has replaced these two tools with Query but since qwinsta and rwinsta is fully compatible with W2K WinXP and W2K3.
So you can use below Commands as well
To displays information about sessions on a remote terminal server.
query session /server:192.168.1.10 (Same as qwinsta)
Note:- 192.168.1.10 is a remote machine ip.
To reset (delete) a session on a terminal server.
reset session /server:192.168.1.10 3 (Same as rwinsta)
Note:- 3 is a session ID