Forum Discussion
Managing disconnected users in AVD hostpool
abhishek02687
Hi, we used to have a GPO that signed out disconnected sessions after about 3 hours due to customers insisting that "we demand being able to be away from the computer for a long time, and when we get back we should not have to sign in again".
This worked fairly OK until some of our customers got a ton of issues with FSLogix "DeadLocks" (earlier versions of FSLogix) due to the disconnected sessions not being able to sign out properly.
After a discussion with MS support they told us we should change the GPO to a maximum 15-30 minutes before disconnected sessions end.
So after that, we tweaked it a bit and implemented the following, and it has worked great ever since, even with the older versions of FSLogix. (The GPOs are probably not overall best practice, and it might not fit your needs, but it works great for us so just wanted to share.
Windows Components/Remote Desktop Services/Remote Desktop Session Host/Session Time Limits
Set time limit for active but idle Remote Desktop Services sessions | Enabled | |
| ||
Set time limit for disconnected sessions | Enabled | |
| ||
Set time limit for logoff of RemoteApp sessions | Enabled | |
|
- Kidd_IpDec 05, 2024MVP
How about PS:
$disconnectedTimeLimit = 30 # Time in minutes Get-RDUserSession | Where-Object { $_.SessionState -eq 'Disconnected' -and $_.DisconnectTime -lt (Get-Date).AddMinutes(-$disconnectedTimeLimit) } | ForEach-Object { Invoke-RDUserLogoff -HostServer $_.HostServer -UnifiedSessionID $_.UnifiedSessionID -Force }
- Ajni KurtajDec 02, 2024Copper Contributor
does this also work on windows 11 multi session ?