You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: support/windows-server/remote/troubleshoot-unexpected-rds-session-locks-or-disconnections.md
+58-52Lines changed: 58 additions & 52 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
---
2
-
title: Troubleshoot unexpected RDS session locks or disconnections
2
+
title: Troubleshoot Unexpected RDS Session Locks or Disconnections
3
3
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
5
5
manager: dcscontentpm
6
6
audience: itpro
7
7
ms.topic: troubleshooting
@@ -12,113 +12,119 @@ ms.custom:
12
12
---
13
13
# Troubleshoot unexpected RDS session locks or disconnections
14
14
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.
16
16
17
-
## Introductions
17
+
## Introduction
18
18
19
-
RDS can have the following status:
19
+
RDS can have the following statuses:
20
20
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.
25
25
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.
27
27
28
-
## Verify if the session time-out is a disconnect
28
+
## Verify if the session time-out is a disconnection
29
29
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.
31
31
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 |
| 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. |
| 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. |
36
36
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.
38
38
39
-
### RDS Deployment
39
+
### RDS deployment
40
40
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.
42
42
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`.
44
44
45
45
> [!NOTE]
46
46
>
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.**
49
49
50
-
### Computer and User policies
50
+
### Computer and user policies
51
51
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:
53
53
**Administrative Templates > Windows Components > Remote Desktop Services > Remote Desktop Session Host > Session Time Limits**
54
54
55
-
Policy configurations are applied to the corresponding registry path:
55
+
Policy configurations are applied to the corresponding registry paths:
- User policy registry path: **HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows NT\Terminal Services**
59
59
60
60
> [!IMPORTANT]
61
61
>
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.
66
66
67
-
## Verify if the session time-out is a Lock
67
+
## Verify if the session time-out is a lock
68
68
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:
70
70
71
-
1.**Machine inactivity limit** policy.
72
-
2.Configuring a **Screen saver**.
71
+
1.The **Machine inactivity limit** policy.
72
+
2.**Screen saver**.
73
73
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.
75
75
76
76
> [!IMPORTANT]
77
77
>
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.
80
80
81
81
### Machine inactivity limit policy
82
82
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:
1. Open Command Prompt and run the following command to open the console:
107
105
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`
109
115
110
116
#### Policies
111
117
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**.
113
119
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:
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:
0 commit comments