Contents

VDI gray screen or continuous reboot loop

Website Visitors:
Contents

https://www.mediafire.com/convkey/27ce/cj0vter3d0rhj997g.jpg

One of the issues I came across recently is, users complained that their VDIs are either not responding on Monday i.e., they just spins for ever or desktop viewer shows up with a gray screen. They have to call helpdesk to reset their VDI. Then they can login and use it till friday.  On Monday same issue re-occurs.

I first checked the tasks history on user’s VDI in VMware. I noticed that there are power on events in VMware almost every day. VMware won’t perform such reboots. So definitely Citrix is sending power off at OS level and power on from VMware end. Using below command, I was able to isolate a Citrix server performing shutdown and turnon commands on these VDIs.

1
Invoke-Command -ScriptBlock{ Get-Eventlog -LogName Application -After 10/26/2018| ? {$_.Message -like "*VDI Name*"} | select TimeGenerated, EntryType, Source,InstanceId,Message} -ComputerName "deliverycontrollers list" 

If it is static VDI catalog group, power management commands should be as shown below so that VDIs are powered on all the time and not shutdown after user logs off.

  • Set-BrokerDesktopGroup “Desktop Group Name” –PeakBufferSizePercent 100
  • Set-BrokerDesktopGroup “Desktop Group Name” –OffPeakBufferSizePercent 100
  • Set-BrokerDesktopGroup “Desktop Group Name” –ShutDownDesktopAfterUse $False
  • Set-BrokerDesktopGroup “Desktop Group Name” –AutomaticPowerOnForAssignedDuringPeak $True
  • Set-BrokerDesktopGroup -Name “Desktop Group Name” -AutomaticPowerOnForAssigned $True

And, Power management should be set to 100% on weekdays and weekends in delivery group GUI ( properties - power management option). If not, with all the above commands are executed, Lets say your weekdays are set to 100% on, and weekends are set to 40% turned on in delivery group GUI. Idle VDIs will shutdown on weekends as power management is set to 40%. XenDesktop will try to power on again because of above powershell commands. So there will be continuous reboot loop. In my case posh commands are executed properly, but weekends are set to 40% in power management GUI. So, on weekends, idle VDIs are turned off, and turned on again immediately. Because of this reboot loop, users were not able to connect to their VDIs.

Want to learn more on Citrix Automations and solutions???

Subscribe to get our latest content by email.

If you like our content, please support us by sponsoring on GitHub below: