One nice feature of Citrix XenDesktop is the ability to adjust the number of powered on desktops for Peak and Off Peak hours. This allows you to configure a different number of available powered on desktops based on time of day and day of week. This feature is sadly missing from VMware Horizon View. There is, however, a way to accomplish the same functionality using View PowerCLI.
For example, on a Connection Server, you can run the following View PowerCLI cmdlet Update-AutomaticLinkedClonePool to set the number of spares to 10 for the linked clone desktop pool “Desktop Pool”.
Update-AutomaticLinkedClonePool -Pool_id “Desktop Pool” -HeadroomCount 10
This will set the Number of spare (powered on) machines for the Desktop Pool to 10 and power on machines to meet this number up to the configured Max number of machines. So if there are 20 desktops in the pool and two people are logged in 10 additional desktops will be powered on and ready to accept connections. If another user consumes a desktop from the pool another desktop will power on to maintain the 10 spare powered on machines up until the Max number of machines is reached.
Run the command again with and specify the HeadroomCount to be 5. As long as the Remote Machine Power Policy for the pool is set to Power off then any spares over the HeadroomCount number will power down.
Update-AutomaticLinkedClonePool -Pool_id “Desktop Pool” -HeadroomCount 5
There are reasons why it is a nice to be able to increase or decrease the number spares in a pool, for example:
- Just prior to start of a shift to help improve user experience.
- To decrease the number of spares on a locally accessed pools on the evening or weekend and increase the number of spares available in pools used for remote access.
- Decrease spares in pools not used during a specific period of time to allow resources to be used for other pools.
Using View PowerCLI and the Windows Task Scheduler you can automate adjusting the spares up or down on a schedule.