Forum Discussion
Change the user assignment in personal host pool
Hi community,
I created host pool as Personal type. We can know the assignment between a user and a host with commandlet "Get-RdsSessionHost", but I can't change the assignment with "Set-RdsSessionHost".
I want to pair a user with a host I intend. How can I do?
- Luis_FarinangoCopper Contributor
Koshinaga If you want to add a user to an app group in your host pool, use following powershell command:
Add-RdsAppGroupUser -TenantName <tenantname> -HostPoolName <hostpoolname> -AppGroupName <"appgroupname"> -UserPrincipalName <userprincipalname>
- KoshinagaCopper Contributor
Sorry for my poor explanation.
App group is already configured, and users can connect the WVD hosts.
There are 2 hosts, WVD-0 and WVD-1(host names). When User0 use WVD, always connect with WVD-1. And when User1 use WVD, always connect with WVD-0.
We can know the pairing with the following Powershell commandlet.
Get-RdsSessionHost -TenantName <tenantname> -HostPoolName <"hostpoolname"> | select SessionHostName,AssignedUser
The pairing was set automatically in the first connect, but I want to let User0 connect with WVD-0 host.
- Luis_FarinangoCopper Contributor
Koshinaga Oh okay, what you can do is sign off the user (User0) from WVD-01 when the user is in the session. Then set the AllowNewSession for the WVD-01 to $false so that your user does not connect to WVD-01 anymore when he logs back in.
You can change the allownewsession setting with following command:
Set-RdsSessionHost -TenantName "contoso" -HostPoolName "contosoHostPool" -Name "sh1.contoso.com" -AllowNewSession $false