Termservice Remote Desktop Services
But in some cases restarting terminal services could be possible by killing the svchost process that runs the terminal services.We can use tasklist and taskkill commands for this. First get the process id of the terminal services process tasklist /svc findstr /C:TermService. Check if Terminal services is the only service running in this svchost. As the name suggests, the Remote Desktop feature in Windows, helps us to access another computer from our computer remotely. This feature plays an important role to solve issues on our system, in. Remote Desktop Services (TermService) Defaults in Windows 10. Allows users to connect interactively to a remote computer. Remote Desktop and Remote Desktop Session Host Server depend on this service. To prevent remote use of your computer, clear the checkboxes on the Remote tab of the System properties control panel item. Default Settings.
I have a domain which has a virtual environment as well as several physical machines (mostly laptops). RDP is enabled via group policy.
-->Applies to: Windows Server (Semi-Annual Channel), Windows Server 2019, Windows Server 2016, Windows Server 2012 R2, Windows Server 2012
Learn about the available Remote Desktop Services (Terminal Services) command-line tools, with descriptions and links for more detailed information.
Note
To find out what's new in the latest version, see What's New in Remote Desktop Services in Windows Server.
Command | Description |
---|---|
change | Changes the Remote Desktop Session Host server settings for sign in, COM port mappings, and install mode. |
change logon | Enables or disables logons from client sessions on an Remote Desktop Session Host server, or displays current logon status. |
change port | Lists or changes the COM port mappings to be compatible with MS-DOS applications. |
change user | Changes the install mode for the Remote Desktop Session Host server. |
chglogon | Enables or disables logons from client sessions on an Remote Desktop Session Host server, or displays current logon status. |
chgport | Lists or changes the COM port mappings to be compatible with MS-DOS applications. |
chgusr | Changes the install mode for the Remote Desktop Session Host server. |
flattemp | Enables or disables flat temporary folders. |
logoff | Signs out a user from a session on an Remote Desktop Session Host server and deletes the session from the server. |
msg | Sends a message to a user on an Remote Desktop Session Host server. |
mstsc | Creates connections to Remote Desktop Session Host servers or other remote computers. |
qappsrv | Displays a list of all Remote Desktop Session Host servers on the network. |
qprocess | Displays information about processes that are running on an Remote Desktop Session Host server. |
query | Displays information about processes, sessions, and Remote Desktop Session Host servers. |
query process | Displays information about processes that are running on an Remote Desktop Session Host server. |
query session | Displays information about sessions on an Remote Desktop Session Host server. |
query termserver | Displays a list of all Remote Desktop Session Host servers on the network. |
query user | Displays information about user sessions on an Remote Desktop Session Host server. |
quser | Displays information about user sessions on an Remote Desktop Session Host server. |
qwinsta | Displays information about sessions on an Remote Desktop Session Host server. |
rdpsign | Enables you to digitally sign a Remote Desktop Protocol (.rdp) file. |
reset session | Enables you to reset (delete) a session on an Remote Desktop Session Host server. |
rwinsta | Enables you to reset (delete) a session on an Remote Desktop Session Host server. |
shadow | Enables you to remotely control an active session of another user on an Remote Desktop Session Host server. |
tscon | Connects to another session on an Remote Desktop Session Host server. |
tsdiscon | Disconnects a session from an Remote Desktop Session Host server. |
tskill | Ends a process running in a session on an Remote Desktop Session Host server. |
tsprof | Copies the Remote Desktop Services user configuration information from one user to another. |
Additional References
We can start Terminal Services by running the command given below.
If the service is already running you will get the message ‘The requested service has already been started.‘
Sometimes you may get an error that the service could not be started.
This happens when Terminal Services is disabled through registry hack. You can fix this by running the below registry change command.
You need to reboot the computer for the changes to take effect. After reboot terminal services starts automatically or you can start the service using net start command as mentioned above.
How to stop Terminal Services?
Terminal Services can’t be stopped like other services. You get the below error when you attempt the same.
How to restart Terminal services?
Since Terminal Services can’t be stopped there is no straightforward way we can do this. Microsoft says this is by design. But in some cases restarting terminal services could be possible by killing the svchost process that runs the terminal services.We can use tasklist and taskkill commands for this.
First get the process id of the terminal services process
Check if Terminal services is the only service running in this svchost. If the svchost is shared with other services then you can stop reading further. Restarting terminal services is not possible on your machine.
On my system I have got the following output.
How to disable Terminal Services?
We can run the below command to disable terminal services.
How to enable Terminal Services?
Termservice Remote Desktop Services Home
(or)