Why does my Azure Virtual Desktop Session host gets unavailable?

Leonard Schwenk 25 Reputation points
2023-05-23T09:56:50.3566667+00:00

I have an Azure Virtual Desktop host pool with a main virtual machine (VM) serving as a session host. This VM was created from a backup of the previous session host.

I then reconnected the VM to the domain and reinstalled the AVD agent using the HP key.

Every day, the machine becomes "unavailable," preventing users from logging in at least once, and I am unsure of the cause.

For the majority of the day, everything functions properly, but after a random period of time, usually a few hours, the machine becomes unavailable and needs to be stopped and started again.

I'm unsure of what steps to take, as the error logs provide limited information, and Microsoft Support hasn't been very helpful.

The machine is not close to its capacity limits.

Upon investigating the issue, I have come up with several potential problems, but I don't have solutions for them:

  • The previous agent may still be present in some way.
  • The agent might not be compatible with the current image, even though it is an Office image restored from a backup disk.
  • I have created the VM first and then attached it to the host pool, whereas I should have created the VM directly from the host pool and then swapped the operating system.
  • The "enablevmaccess" extension may not be available.
  • The SxS Network Stack agent appears to be installed twice for some unknown reason. [List item

](https://i.stack.imgur.com/qxKnT.png)
These are just some ideas I have, and I'm unsure if they are related to the problem at all.
I would love to not have to stop and start the vm every day at a random time.

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
8,134 questions
Azure Virtual Desktop
Azure Virtual Desktop
A Microsoft desktop and app virtualization service that runs on Azure. Previously known as Windows Virtual Desktop.
1,603 questions
{count} votes

1 answer

Sort by: Most helpful
  1. vipullag-MSFT 26,411 Reputation points
    2023-05-23T12:32:13.2666667+00:00

    Hello Leonard Schwenk

    Welcome to Microsoft Q&A Platform, thanks for posting your query here.
    I checked with internal team on this, one user had similar issue before when a agent did not re-register right.

    The suggested troubleshooting steps here (https://learn.microsoft.com/en-us/azure/virtual-desktop/troubleshoot-agent) helped resolve the issue. left over components can be in HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\RDInfraAgent

    Hope this helps.


Your answer

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