Forum Discussion
hippygold
Apr 22, 2021Copper Contributor
What is the Tenant Name when creating host pools via the portal
Hi, Some of the PS cmdlets require a tenant name to work. I have a couple of tenants which were created when I started looking at WVD but none of them seem to the related to the newer host pools whi...
YannickJanssens1986
Apr 22, 2021Brass Contributor
I think you are looking at old cmdlets from before that WVD was manageable via the portal (in other words before; the Spring release of WVD when it became an ARM service).
Old cmdlets look like, for example: Get-RDSSessionHost
New cmdlet will look like : Get-AzWVDSessionHost
Check here for all the new ones:
https://docs.microsoft.com/en-us/powershell/module/az.desktopvirtualization/?view=azps-5.8.0
- hippygoldApr 22, 2021Copper ContributorMany thanks for the reply, using the new ones already however I wanted to be able to query application group assignments which seems to be Get-RdsAppGroupUser which requires a TenantName to work.
- YannickJanssens1986Apr 22, 2021Brass Contributor
Try this
$AG = Get-AzWvdApplicationGroup -Name <AppGroupNameHere> -ResourceGroupName <RG name here>
Get-AzRoleAssignment -Scope $AG.id | Where-Object{$_.RoleDefinitionName -eq "Desktop Virtualization User"}That should list all the users assigned to that group.