Skip to content

Commit 1b8ab7c

Browse files
authored
Updates from editor
1 parent c10633d commit 1b8ab7c

1 file changed

Lines changed: 58 additions & 52 deletions

File tree

support/windows-server/remote/troubleshoot-unexpected-rds-session-locks-or-disconnections.md

Lines changed: 58 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: Troubleshoot unexpected RDS session locks or disconnections
2+
title: Troubleshoot Unexpected RDS Session Locks or Disconnections
33
description: Introduces how to configure RDS session time-outs to troubleshoot unexpected session locks or disconnections.
4-
ms.date: 01/15/2025
4+
ms.date: 03/11/2025
55
manager: dcscontentpm
66
audience: itpro
77
ms.topic: troubleshooting
@@ -12,113 +12,119 @@ ms.custom:
1212
---
1313
# Troubleshoot unexpected RDS session locks or disconnections
1414

15-
A Remote Desktop Services (RDS) session can enter **locks** and **disconnects** status at regular intervals. In this situation, the session requires users to sign in or reconnect to the session. This article introduces how to troubleshoot unexpected **locks** and **disconnects** time intervals.
15+
A Remote Desktop Services (RDS) session can enter a **locked** and **disconnected** status at regular intervals. In this situation, the session requires users to sign in or reconnect to the session. This article introduces how to troubleshoot unexpected lock and disconnection time intervals.
1616

17-
## Introductions
17+
## Introduction
1818

19-
RDS can have the following status:
19+
RDS can have the following statuses:
2020

21-
- **active**: the user is currently connected and interacting with the system.
22-
- **idle**: the user is connected but hasn't interacted with the server for a specific period.
23-
- **locked**: users are redirected to the login screen, but their sessions remain active without any error message.
24-
- **disconnected**: The user's connection to the server has been severed, and then the RDP window typically closes with an error message. The session remains to run on the server.
21+
- **Active**: The user is currently connected and interacting with the system.
22+
- **Idle**: The user is connected but hasn't interacted with the server for a specific period.
23+
- **Locked**: Users are redirected to the login screen, but their sessions remain active without any error message.
24+
- **Disconnected**: The user's connection to the server has been severed, and then the RDP window typically closes with an error message. The session remains to run on the server.
2525

26-
Disconnects occurring without a consistent timing pattern are more likely caused by **network issues** rather than configuration settings.
26+
Disconnections occurring without a consistent timing pattern are more likely caused by network issues rather than configuration settings.
2727

28-
## Verify if the session time-out is a disconnect
28+
## Verify if the session time-out is a disconnection
2929

30-
On a Windows computer, when **MaxIdleTime** or **MaxConnectionTime** are configured, RDS sessions disconnect when conditions are met with distinct messages. Additional RDS session time limit policies determine the behavior after a session is disconnected.
30+
On a Windows computer, when **MaxIdleTime** or **MaxConnectionTime** is configured, RDS sessions disconnect when conditions are met with distinct messages. Other RDS session time limit policies determine the behavior after a session is disconnected.
3131

32-
| Configuration | Set time limit for active but idle RDS sessions | Set time limit for active RDS sessions |
32+
| Configuration | Set a time limit for active but idle RDS sessions | Set a time limit for active RDS sessions |
3333
| :------------------------ | :-------------------------------------------------------------------------------------------------------- | :--------------------------------------------------------------------------------------------------------------------------------------------- |
34-
| Registry (Type:REG_DWORD) | MaxIdleTime | MaxConnectionTime |
35-
| Message when disconnected | Your Remote Desktop Services session ended because the remote computer didn't receive any input from you. | The remote session ended because the total sign-in time limit was reached. This limit is set by the server administrator or by network policies. |
34+
| Registry (Type: `REG_DWORD`) | `MaxIdleTime` | `MaxConnectionTime` |
35+
| Message when disconnected | Your Remote Desktop Services session ended because the remote computer didn't receive any input from you. | The remote session ended because the total logon time limit was reached. This limit is set by the server administrator or by network policies. |
3636

37-
You can use the following two methods to configure the above registry values.
37+
You can use the following two methods to configure these registry values.
3838

39-
### RDS Deployment
39+
### RDS deployment
4040

41-
The default configuration for these session limits should be set at the **Collection** > **Properties tasks** > **Session** on the server that manages the RDS deployment. Usually, the server is the Remote Desktop Connection Broker. These settings are then applied to the registry of the Remote Desktop Session Hosts in that collection.
41+
The default configuration for these session limits should be set in **Collection** > **Properties tasks** > **Session** on the server that manages the RDS deployment. Usually, the server is the Remote Desktop Connection Broker. These settings are then applied to the registries of the Remote Desktop Session Hosts in that collection.
4242

43-
The registry values locate at `Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp`.
43+
The registry values are located at `Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server\WinStations\RDP-Tcp`.
4444

4545
> [!NOTE]
4646
>
47-
> - If you connect to the RDS Deployment through a Remote Desktop Gateway (RDGW), similar configuration can be done in **RDGW manager > Policies > Connection Authorization Policies > Timeouts tab**. Users that bypass the RDGW won't be affected.
48-
> - Session time-out has a distinct disconnect message compared to the message caused by the **MaxConnectionTime** setting: **The connection has been disconnected because the session timeout limit was reached.**
47+
> - If you connect to the RDS deployment through a Remote Desktop Gateway (RDGW), a similar configuration can be done in **RDGW manager > Policies > Connection Authorization Policies > Timeouts tab**. Users who bypass the RDGW won't be affected.
48+
> - The session time-out disconnection message is distinct from the message caused by the **MaxConnectionTime** setting: **The connection has been disconnected because the session timeout limit was reached.**
4949
50-
### Computer and User policies
50+
### Computer and user policies
5151

52-
Computer and User policies should be configured with **gpedit.msc** (locally) or **gpmc.msc** (domain level) on the following path:
52+
Computer and user policies should be configured with **gpedit.msc** (locally) or **gpmc.msc** (domain level) at the following path:
5353
**Administrative Templates > Windows Components > Remote Desktop Services > Remote Desktop Session Host > Session Time Limits**
5454

55-
Policy configurations are applied to the corresponding registry path:
55+
Policy configurations are applied to the corresponding registry paths:
5656

5757
- Computer policy registry path: **HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services**
5858
- User policy registry path: **HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows NT\Terminal Services**
5959

6060
> [!IMPORTANT]
6161
>
62-
> - Policies have precedence to default configurations.
63-
> - Computer policies have precedence to user policies.
64-
> - Registry values are expressed in miliseconds.
65-
> - For these configurations to apply, users must reconnect or logoff/logon.
62+
> - Policies have precedence over default configurations.
63+
> - Computer policies have precedence over user policies.
64+
> - Registry values are expressed in milliseconds.
65+
> - To apply these configurations, users must reconnect or log off/on.
6666
67-
## Verify if the session time-out is a Lock
67+
## Verify if the session time-out is a lock
6868

69-
On a Windows machine, there are two distinct forms of configuring a session lock:
69+
On a Windows machine, there are two distinct forms of a session lock configuration:
7070

71-
1. **Machine inactivity limit** policy.
72-
2. Configuring a **Screen saver**.
71+
1. The **Machine inactivity limit** policy.
72+
2. **Screen saver**.
7373

74-
If any of the above settings is configured, sessions are locked when conditions are met.
74+
If any of the preceding settings are configured, sessions are locked when conditions are met.
7575

7676
> [!IMPORTANT]
7777
>
78-
> - Policies have precedence to default configurations.
79-
> - These configurations apply immediately, but if not, ask users to reconnect or logoff/logon.
78+
> - Policies have precedence over default configurations.
79+
> - These configurations apply immediately, but if not, ask users to reconnect or log off/on.
8080
8181
### Machine inactivity limit policy
8282

83-
The policy can only be configured at the Computer level, with the value specified in seconds. The following are the configuration policy path and the corresponding registry path:
83+
This policy can only be configured at the computer level, with the value specified in seconds. Here are the configuration policy path and the corresponding registry path:
8484

8585
- Policy path: **Computer Configuration > Windows Settings > Security Settings > Local Policies > Security Options** - **Interactive logon: Machine inactivity limit**
86-
- Registry path: Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System - InactivityTimeoutSecs
87-
Type:REG_DWORD
86+
- Registry path: `Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System - InactivityTimeoutSecs`
87+
88+
Type: `REG_DWORD`
8889

8990
### Screen saver
9091

91-
To enable a screen saver that locks the session, three registry values of type:REG_SZ must be configured:
92+
To enable a screen saver that locks the session, three registry values of type `REG_SZ` must be configured:
9293

93-
- **ScreenSaveActive** - Enable (**1**) or Disable (**0**) a Screen Saver
94-
- **ScreenSaverIsSecure** - Password protected (**1**) or unprotected (**0**)
95-
- **ScreenSaveTimeOut** - How much user idle time (seconds) must elapse before the screen saver is launched
94+
- **ScreenSaveActive** - Enable (**1**) or disable (**0**) the screen saver.
95+
- **ScreenSaverIsSecure** - Password protected (**1**) or unprotected (**0**).
96+
- **ScreenSaveTimeOut** - How much user idle time (in seconds) must elapse before the screen saver is launched.
9697

97-
Screen saver is a user configuration. The configuration can be set by using **Screen Saver Settings** console or by using policies.
98+
Screen saver is a user configuration. The configuration can be set by using the **Screen Saver Settings** console or using policies.
9899

99100
#### Screen Saver Settings
100101

101-
To configure on Screen Saver Settings:
102+
To configure on **Screen Saver Settings**:
102103

103-
- open CMD and run following command to open the console: *control desk.cpl,,1*
104-
- Select from **Screen saver** dropdown box.
105-
- Define a time-out.
106-
- Select **On resume, display logon screen** checkbox.
104+
1. Open Command Prompt and run the following command to open the console:
107105

108-
Values are written on registry path: `Computer\HKEY_CURRENT_USER\Control Panel\Desktop`
106+
```cmd
107+
control desk.cpl,,1
108+
```
109+
110+
2. Select from the **Screen saver** dropdown box.
111+
3. Define a time-out.
112+
4. Select the **On resume, display logon screen** checkbox.
113+
114+
The values are written in the registry path: `Computer\HKEY_CURRENT_USER\Control Panel\Desktop`
109115
110116
#### Policies
111117
112-
Three below policies must be configured to enable Screen Saver: **Enable screen saver**, **Password protect the screen saver**, and **Screen saver timeout**.
118+
Three policies must be configured to enable the screen Saver: **Enable screen saver**, **Password protect the screen saver**, and **Screen saver timeout**.
113119
114-
The following are the configuration policies path and the corresponding registry path:
120+
Here are the configuration policy path and the corresponding registry path:
115121
116122
- Policy path: **User Configuration > Administrative Templates > Control Panel > Personalization**.
117123
- Registry path: `Computer\HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\Control Panel\Desktop`.
118124
119125
## Contact Microsoft Support
120126
121-
If the preceding steps can't resolve the issue, collect data on the affected machine while replicating the issue. Download [TSS script](https://aka.ms/getTSS), and run the following command on an elevated PowerShell:
127+
If the preceding steps can't resolve the issue, collect data on the affected machine while replicating the issue. Download [the TroubleShootingScript (TSS) script](https://aka.ms/getTSS) and run the following command on an elevated PowerShell prompt:
122128
123129
```powershell
124130
.\TSS.ps1 -Scenario UEX_RDSsrv -start -UEX_Logon

0 commit comments

Comments
 (0)