This will not reclaim any space. However there is an alternative, we can use the PowerShell to change the settings.
First I have run a Get to show the current settings. As you can see the current settings are set as follows. The action is set to do nothing and the timer is set to 0 minutes. There is a couple of option you may want to change depending on when you want your desktops to shut down. You can set these setting for Peak hours and/or OffPeak Hours.
Get-BrokerDesktopGroup "DesktopGroupName"
Now I am going to run two PS commands to set the OffPeak and PeakDisconnectTimeout. (I am only using 5 min in my demo environment)
Set-BrokerDesktopGroup "DesktopGroupName" -OffPeakDisconnectTimeout 5
Set-BrokerDesktopGroup "DesktopGroupName" -PeakDisconnectTimeout 5
Now I am going to run two PS commands to set the action to Shut down this will then reclaim the space if users leave their desktop in a disconnected state.
Set-BrokerDesktopGroup "DesktopGroupName" -OffPeakDisconnectAction Shutdown
Set-BrokerDesktopGroup "DesktopGroupName" -PeakDisconnectAction Shutdown
And there you go now when a user disconnects from the session it will remain disconnected until the time out is hit then the desktop will shutdown as detailed in the action.
No comments:
Post a Comment