Share via

How persist registration tokens on AVD Host Pool on Sponsorship subscription?

Crispin Flower 0 Reputation points
2026-02-08T13:06:20.5466667+00:00

My host pools cannot persist registration tokens. The registrationInfo field remains null even after generating a key. As a result, session hosts do not work correctly. How do I enable AVD registration token capability on my Sponsorship subscription?

Azure Virtual Desktop
Azure Virtual Desktop

A Microsoft desktop and app virtualization service that runs on Azure. Previously known as Windows Virtual Desktop.

{count} votes

3 answers

Sort by: Most helpful
  1. TP 152.5K Reputation points Volunteer Moderator
    2026-02-08T18:08:57.82+00:00

    Hi,

    It's normal for registrationInfo to be null when using latest Get API to retrieve host pool details. To retrieve existing registration token you need to call different API.

    For example, you may use Azure Cloud Shell (Bash mode) to execute Azure CLI command similar to below to get token:

    az desktopvirtualization hostpool retrieve-registration-token --name mypool --resource-group my-resource-group --subscription xxxxxxxx-xxxx-4xxx-xxxx-xxxxxxxxxxxx
    
    

    Output similar to below screenshot:

    User's image

    Please see article below for steps to manually register host to a host pool.

    Register session hosts to a host pool

    https://learn.microsoft.com/en-us/azure/virtual-desktop/add-session-hosts-host-pool?tabs=portal%2Cgui&pivots=host-pool-standard#register-session-hosts-to-a-host-pool

    Please click Accept Answer and upvote if the above was helpful.

    Thanks.

    -TP


  2. Nikhil Duserla 9,685 Reputation points Microsoft External Staff Moderator
    2026-02-08T16:24:56.5666667+00:00

    Hello @Crispin Flower ,

    It looks like you're having trouble with publishing AVD session hosts on your Sponsorship subscription due to the registration token not persisting. Here’s a step-by-step guide to tackle this issue:

    Troubleshooting Steps:

    Generate a New Registration Key:

    • Sign in to the Azure portal.
      • Go to Azure Virtual Desktop > Host pools and select your host pool.
        • Click on Registration keys and then choose Generate new key.
          • You can set the expiration date of the key between 1 hour and 27 days. Make sure to copy this key.
          Update the Session Host with the New Registration Token:
                - On your session host VM, open PowerShell as an administrator and run the following commands:
                
                
          
          $newKey = '<NewRegistrationToken>'

    Set-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\RDInfraAgent" -Name "RegistrationToken" -Value $newKey -Force

    Restart-Service RDAgentBootLoader ```

               **Verify the Registration:**
    
               
                  You can check if the session host is registered correctly by running:
    
                  
                  ```
                  Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\RDInfraAgent" -Name IsRegistered | FL IsRegistered
    ```Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\RDInfraAgent" -Name RegistrationToken | FL RegistrationToken
                      ```
                      
    ```powershell
                     The expected output should show `IsRegistered : 1` and `RegistrationToken : `(which should be blank).
    
                     
                     **Check Session Host Status:**
    
                     
                        - Go back to the Azure portal and check if the session host now appears as 'Available' within 5-10 minutes.
    ```### **Follow-Up Questions:**
    
    If the issue persists, it would be helpful to know:
    
    - Are you running into any specific error messages in Event Viewer related to tokens or registration?
    
    - How long have the VMs been deallocated?
    
    - Have there been any recent changes to your network security or firewall settings that might block the necessary endpoints?
    
    ### **References:**
    
    - [Troubleshoot common Azure Virtual Desktop Agent issues](https://learn.microsoft.com/troubleshoot/azure/virtual-desktop/troubleshoot-agent)
    
    - [Azure Virtual Desktop session host health checks](https://learn.microsoft.com/azure/virtual-desktop/session-host-status-health-checks)
    
    - [Generate a registration key for a host pool](https://learn.microsoft.com/en-us/azure/virtual-desktop/add-session-hosts-host-pool#generate-a-registration-key)
    
    Hope this helps, and let me know if you need further assistance!
    
    Was this helpful? 
    
    0 comments No comments

  3. SUNOJ KUMAR YELURU 17,986 Reputation points MVP Volunteer Moderator
    2026-02-08T14:02:20.2966667+00:00

    Hello @Crispin Flower,

    You need to generate a registration key for your host pool. This key authorizes session hosts to join the host pool and is valid only for the duration you specify. Here are the steps to generate a registration key using the Azure portal:

    1. Sign in to the Azure portal.
    2. Search for Azure Virtual Desktop and select it.
    3. Navigate to Host pools and select the host pool for which you want to generate a registration key.
    4. In the host pool overview, select Registration key.
    5. Click on Generate new key, set an expiration date and time, and then select OK. The registration key will be created.
    6. You can download the key or copy it to your clipboard for later use.

    If you encounter issues where the registrationInfo field remains null, it may be due to using an invalid or expired token. In such cases, you should create a new registration key and update the session host with this new token. You can verify the registration status by checking the Event Viewer on your session host VM for any errors related to the registration token.


    If this answers your query, do click Accept Answer and Up-Vote for the same. And, if you have any further query do let us know.


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.