This is a blogpost about how to create a WVD HostPool. I demonstrate two methods. The GUI based method and the Powershell method. In addition, you can also create the Hostpool via an ARM template but that’s a topic for another time.
The GUI based method
Firstly, log on to Microsoft Azure.
After that, go to Windows Virtual Desktop:
Click on Host pools:
After that, click on add:
A new blade is shown. Firstly, you need to fill in the basics:
Choose a subscription, resource group, hostpool name and location for your metadata. (West Europe is now available)
A validation environment lets you test services that are made available by the WVD team at Microsoft. Apply this only to your development or test hostpools!
Next up is the Hostpool type. Personal is the VDI option (1 user per machine). Pooled is the multi-user option. We are going with Pooled.
The load balancing algorithm is very important. Breadth-first is the method which spreads out the users on the available VM’s as much as possible. Depth-first fills up a WVD host first and if that host reaches the Max session limit the next machine will be filled up. For auto-scaling purposes it is more easy and economical to use Depth-first.
Next up is the option to create Virtual Machine. I don’t use this option because I deploy my VM’s via Azure DevOps.
At the workspace tab you can register an desktop app group. I always choose to do so. Furthermore, I also register a workspace per hostpool:
Apply tags if you want to and after that click on review + create:
Finally, click on create to create the hostpool:
That’s how you create a WVD hostpool via the GUI for Microsoft Azure.
The Powershell Method
Obviously, this is my favorite method to create a WVD Hostpool.
Firstly, log on to Microsoft Azure using the following code:
Connect-AzAccount
Next up, set the correct subscription:
Select-AzSubscription -SubscriptionId SUBSCRIPTION_ID | Set-AzContext
Now, we create 3 resources. The WVD Workspace, Hostpool and Desktop Application Group.
Firstly, we use this code to create the workspace (fill in the parameters accordingly).
New-AzWvdWorkspace -ResourceGroupName 'WVD' ` -Name 'WVD-Test' ` -Location 'westeurope' ` -FriendlyName 'WVD Test' ` -ApplicationGroupReference $null ` -Description 'WVD Test'
Next up is the WVD hostpool: (fill in the parameters accordingly)
New-AzWvdHostPool -Name 'WVD-Testing' ` -ResourceGroupName 'WVD' ` -Location 'WestEurope' ` -HostPoolType Pooled ` -PreferredAppGroupType 'Desktop' ` -LoadBalancerType DepthFirst ` -MaxSessionLimit '12'
We are going to create the Desktop Application Group. We first need to grab the resource id from the hostpool that we just created:
$HostPool = Get-AzWvdHostPool -Name 'WVD-Testing' -ResourceGroupName 'WVD'
After that we can create the Desktop Application Group: (fill in the parameters accordingly)
New-AzWvdApplicationGroup -Name 'WVD-Testing-DAG' ` -ResourceGroupName 'WVD' ` -ApplicationGroupType 'Desktop' ` -HostPoolArmPath $HostPool.id ` -Location 'WestEurope'
Lastly, we are registering the Desktop Application Group to the workspace.
First, grab the resource id for the Desktop Application Group:
$DAG = Get-AzWvdApplicationGroup -Name 'WVD-Testing-DAG' -ResourceGroupName 'WVD'
Then we register the Desktop Application Group to the Workspace:
Register-AzWvdApplicationGroup -ResourceGroupName 'WVD' ` -WorkspaceName 'WVD-Test' ` -ApplicationGroupPath $DAG.id
The result is these resources have been created:
References
Microsoft Docs about hostpools
Other Posts:
WVD ARM Template Update
WVD HostPool registration key
2 thoughts on “WVD Create HostPool”