Moving VDI Deployments: Step 3 – Prep Azure / AVD Environment

This post is part of a series of posts showing how you might move an existing VDI deployment to Azure Virtual Desktop on Azure Stack HCI.

This post goes over what needs to be done in Azure to setup the AVD host pool to work with VMs on Azure Stack HCI.

Replacing the RDS server roles with AVD is a pretty simple process but does require the creation of a few items in Azure – an Azure Virtual Desktop Host Pool and Application Group.  Creating a host pool with no VMs is all that is needed, as well as a corresponding Application Group to publish a full “Desktop Experience”. 

Pop into the Azure Portal… search for Azure Virtual Desktop, create host pool:

You will create a “Personal” (rather than pooled) host pool since we are migrating personal, persistent VMs from RDS. The VMs already exist, so we do not need to create any in Azure (they will live on our Azure Stack HCI cluster):

Here’s what my empty host pool looks like once it is created (since we haven’t yet connected the VMs):

We also need an “Application Group” – that’s how we assign permissions to the users. Here’s what the App Group looks like:

I’ve already added the Entra ID credentials to my App Group “migration-DAG” for those users I found assigned to the RDS VMs:

Yes, I could have done the assignments programmatically once I “detected” them in the RDS deployment but did them manually before the migration and VM registration.

Once the Host Pool and Application Group are setup properly, you will need to download the Host Pool Registration key to automate the registration of the migrated VMs to the AVD pool.  Here’s the code I used to collect and save that to a file for later use:

$AZResourceGroup 	= "WVD"
$AZSubscriptionID	= "11111111-1111-1111-1111-111111111111"
$AVDHostPool		= "migration"
$WorkPath		= \\rdsinfra\installs
$PoolKeyFile 		= "HostpoolRegistrationKey.txt"

Connect-AzAccount -EnvironmentName AzureUSGovernment
$PoolKey = Get-AzWvdRegistrationInfo -HostPoolName $AVDHostPool -ResourceGroupName $AZResourceGroup -SubscriptionId $AZSubscriptionID
$PoolKeyPath = $WorkPath + "\" + $PoolKeyFile 
$PoolKey.token | Out-file -FilePath $PoolKeyPath

That’s pretty much everything you’ll need to do in Azure!

Next we’ll work on migrating our VMs from RDS to AVD on HCI.