Add existing Azure VM to session host pool (Azure WVD)
There are two solutions how to add live VM to session host pool.
- Uninstall DCS extension on VMs
Uninstall DCS extension on VMs and run the deployment code (Terraform, Bicep) that installs DCS extension with a new registration.
- Reinstall Remote desktop agents with host pool token on VMs
- Download the registration key from Hostpool.
- Sign in to the Azure portal.
- In the search bar, type Azure Virtual Desktop and select the matching service entry.
- Select Host pools, then select the name of the host pool you want to generate a registration key
- Select Download to download a text file containing the registration key, or copy the registration key to your clipboard to use later. You can also retrieve the registration key later by returning to the host pool overview.
- Connect to VM and uninstall 2 agents:
- Remote desktop agent boot loader
- Remote desktop service infrastructure agent
- Download the Agent and the Agent Bootloader installation files using the following links
-
- Run the
Microsoft.RDInfra.RDAgent.Installer-x64-<version>.msi
file to install the Remote Desktop Services Infrastructure Agent. - Follow the prompts and when the installer prompts for the registration token, paste it into the text box, which will appear on a single line. Select Next, then complete the installation.
- Run the
Microsoft.RDInfra.RDAgentBootLoader.Installer-x64.msi
file to install the remaining components. - Follow the prompts and complete the installation.
- After a short time, the virtual machines should now be listed as session hosts in the host pool. The status of the session hosts may initially show as Unavailable and if there is a newer agent version available, it will upgrade automatically.
- Once the status of the session hosts is Available, restart the virtual machines.
- Run the
- Download the registration key from Hostpool.