What is the Tenant Name when creating host pools via the portal

%3CLINGO-SUB%20id%3D%22lingo-sub-2281337%22%20slang%3D%22en-US%22%3EWhat%20is%20the%20Tenant%20Name%20when%20creating%20host%20pools%20via%20the%20portal%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2281337%22%20slang%3D%22en-US%22%3E%3CP%3EHi%2C%3C%2FP%3E%3CP%3ESome%20of%20the%20PS%20cmdlets%20require%20a%20tenant%20name%20to%20work.%20I%20have%20a%20couple%20of%20tenants%20which%20were%20created%20when%20I%20started%20looking%20at%20WVD%20but%20none%20of%20them%20seem%20to%20the%20related%20to%20the%20newer%20host%20pools%20which%20were%20created%20via%20the%20portal.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAny%20idea%20as%20to%20what%20the%20tenant%20name%20maybe%20%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ETIA%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2281672%22%20slang%3D%22en-US%22%3ERe%3A%20What%20is%20the%20Tenant%20Name%20when%20creating%20host%20pools%20via%20the%20portal%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2281672%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F1031702%22%20target%3D%22_blank%22%3E%40hippygold%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3ETry%20this%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%24AG%20%3D%20Get-AzWvdApplicationGroup%20-Name%3CSTRONG%3E%20%3CAPPGROUPNAMEHERE%3E%3C%2FAPPGROUPNAMEHERE%3E%3C%2FSTRONG%3E%20-ResourceGroupName%20%3CSTRONG%3E%3CRG%20name%3D%22%22%20here%3D%22%22%3E%3C%2FRG%3E%3C%2FSTRONG%3E%3C%2FP%3E%3CP%3E%3CBR%20%2F%3EGet-AzRoleAssignment%20-Scope%20%24AG.id%20%7C%20Where-Object%7B%24_.RoleDefinitionName%20-eq%20%22Desktop%20Virtualization%20User%22%7D%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThat%20should%20list%20all%20the%20users%20assigned%20to%20that%20group.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2281509%22%20slang%3D%22en-US%22%3ERe%3A%20What%20is%20the%20Tenant%20Name%20when%20creating%20host%20pools%20via%20the%20portal%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2281509%22%20slang%3D%22en-US%22%3EMany%20thanks%20for%20the%20reply%2C%20using%20the%20new%20ones%20already%20however%20I%20wanted%20to%20be%20able%20to%20query%20application%20group%20assignments%20which%20seems%20to%20be%20Get-RdsAppGroupUser%20which%20requires%20a%20TenantName%20to%20work.%3CBR%20%2F%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2281474%22%20slang%3D%22en-US%22%3ERe%3A%20What%20is%20the%20Tenant%20Name%20when%20creating%20host%20pools%20via%20the%20portal%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2281474%22%20slang%3D%22en-US%22%3E%3CP%3EI%20think%20you%20are%20looking%20at%20old%20cmdlets%20from%20before%20that%20WVD%20was%20manageable%20via%20the%20portal%20(in%20other%20words%20before%3B%20the%20Spring%20release%20of%20WVD%20when%20it%20became%20an%20ARM%20service).%3C%2FP%3E%3CP%3E%3CBR%20%2F%3EOld%20cmdlets%20look%20like%2C%20for%20example%3A%20Get-RDSSessionHost%3CBR%20%2F%3ENew%20cmdlet%20will%20look%20like%20%3A%20Get-AzWVDSessionHost%3CBR%20%2F%3E%3CBR%20%2F%3ECheck%20here%20for%20all%20the%20new%20ones%3A%3CBR%20%2F%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fpowershell%2Fmodule%2Faz.desktopvirtualization%2F%3Fview%3Dazps-5.8.0%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fpowershell%2Fmodule%2Faz.desktopvirtualization%2F%3Fview%3Dazps-5.8.0%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
New Contributor

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 which were created via the portal.

 

Any idea as to what the tenant name maybe ?

 

TIA

3 Replies

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

 

 

Many 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.

@hippygold 

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.