Microsoft KB Archive/320192

= HOW TO: Use the RESET SESSION Command to Reset a Session in Windows 2000 Terminal Services =

Article ID: 320192

Article Last Modified on 10/30/2006

-

APPLIES TO


 * Microsoft Windows 2000 Server
 * Microsoft Windows 2000 Advanced Server
 * Microsoft Windows 2000 Professional Edition

-



This article was previously published under Q320192



IN THIS TASK
SUMMARY
 * Overview of the RESET SESSION Command
 * How to Use the RESET SESSION Command to Reset a Session

REFERENCES



SUMMARY
This step-by-step article describes how to use the reset session command to reset a client session in Windows 2000 Terminal Services.

You can use either Terminal Services Manager or the reset session command to reset a Terminal Services session. If you reset a user's session, all of the programs that are currently running are closed and the session is immediately deleted from the server that is running Terminal Services. You may want to reset a session in situations in which the session is not functioning correctly or if the session has stopped responding.

back to the top

Overview of the RESET SESSION Command
The reset session command uses the following syntax:

reset session [ /server:  ] /v

reset session [ /server:  ] /v

The following list describes the parameters that you can use with the reset session command:
 *  : Use this parameter to specify the name of the session that you want to reset. To determine the name of the session that you want to reset, use the query session command.
 *  : Use this parameter to specify the identification number (ID) of the session that you want to reset. To determine the ID of a session that you want to reset, use the query session command.
 * /server : Use this parameter to specify a Terminal server that contains the session that you want to reset. Use this parameter only if you use reset session from a remote server. If you omit this parameter, the current Terminal server is specified.
 * /v: Use this parameter to display information about the actions that are performed if you run the reset session command.

NOTE: You can reset your own sessions; however, if you want to reset another user's session, you must have Full Control access permission.

back to the top

How to Use the RESET SESSION Command to Reset a Session
The following example describes how to use the reset session command to reset a session on the current Terminal server:  Click Start, and then click Run. Type cmd in the Open box, and then click OK.  Type query session at the command prompt, and then press ENTER to determine the name or the ID of the session that you want to reset.

You receive a list that describes the sessions on the current Terminal server. The list may look similar to the following list: SESSIONNAME   USERNAME       ID STATE  TYPE   DEVICE >console       administrator   0 active wdcon rdp-tcp#1     user1           1 active rdpwd rdp-tcp                   65536 listen rdpwd 2 idle 3 idle  To reset the session of user1 by using the session name, type the following line at the command prompt, and then press ENTER:

reset session rdp-tcp#1

User1 receives the following message:

The Terminal server has ended the connection.

 To reset the session of user1 by using the session ID, type the following line at the command prompt, and then press ENTER:

reset session 1

User1 receives the following message:

The Terminal server has ended the connection.



back to the top

<div class="references_section">