Quantcast
Channel: Carl Stalhood
Viewing all articles
Browse latest Browse all 594

VMware Horizon 7 – Virtual Desktop Pools

$
0
0

This topic details Horizon configuration for Virtual Desktop Agents. RDS Farms are detailed at http://www.carlstalhood.com/vmware-horizon-7-rds-farmspools/.

Navigation

Non-Persistent – Instant Clone vs Composer

In general, use Instant Clone, if possible. Here are some advantages of Instant Clone over Composer:

  • No Composer server needed
  • Faster provisioning and recompose – lower IOPS during these operations
  • Instant Clones are always non-persistent. Composer can be mis-configured to not refresh or delete on logoff.
  • If multiple datastores, rebalance is automatic. With Composer, rebalance is a manual operation.
  • Confusing Composer features like Persistent Disks, Disposable Disks, disk space reclamation, etc. are not needed with Instant Clones. Replica Storage Tiering is still an option for Instant Clone.

Requirements for Instant Clones:

  • Horizon Enterprise licenses
  • ESXi 6 Update 1 or newer
  • Virtual Machine hardware version 11 or newer
  • View Storage Accelerator must be enabled

Limitations of Instant Clones:

  • Virtual Desktops only – RDSH is not supported
  • Floating Pools only – Dedicated pools are not supported
  • No 3D Rendering
  • Like Composer, the master VM snapshot is copied to every LUN containing linked clones. Unlike Composer, an additional machine called the “parent” machine is created on each host and each datastore. These “parent” machines are powered on and consume CPU/Memory/Disk resources.
  • The Master VM and the snapshot used by the Instant Clones cannot be deleted.

Infrastructure Prep

  • Each pool points to one vSphere cluster. 32 hosts maximum. If Virtual SAN, 20 hosts maximum.
  • Ensure vSwitch has sufficient ports for the new virtual desktops.
  • Ensure the VLAN has enough DHCP addresses for the desktop pool.
    • Lower the DHCP lease time too.
  • KMS Licensing is required for Windows 7+ and/or Office 2010+
  • The virtual desktop pools will use the same hardware specs (e.g. vCPUs, memory size, network label) specified on the master virtual desktop. Adjust accordingly.
  • The parent image should be in the same cluster where the linked clone virtual desktops will be created.
  • If Instant Clone:

Disk space:

  • One or more LUNs for storage of the virtual desktops. Maximum of 140 desktops per VMFS5 LUN. 250+ desktops per NFS LUN.
  • By default, Replicas are copied to each LUN that contains virtual desktops. It’s possible to place the Replica and the linked clones on separate LUNs. If you use a dedicated Replica LUN, then there is only one copy of the Replica no matter how many LUNs are used for storing virtual desktops. Note: NFS VAAI requires Replica to be copied to each virtual desktop LUN.
    • If Instant Clone, the “parent” VM on each datastore is powered on and consumes CPU, Memory, and disk space (.vmdk and .vswp).
  • If Composer:
    • Persistent disks can be used to store the user’s profile (but not user-installed applications). To enable Persistent disks, the pool must be Dedicated Assignment. You can place the persistent disks on a LUN that is separate from the linked clones LUN. A better option is to use View Persona or User Environment Manager instead of Persistent disks.
    • Disposable disks. In Dedicated Assignment pools, you have the option of creating Disposable Disks. These disks are always stored with the virtual desktop (you can’t choose a dedicated disposable disk LUN). If you’re planning to frequently refresh the desktops, there’s no point in using Disposable disks.
  • .vswp files. Allocate disk space for memory swap and graphics memory overhead. Any unreserved memory will result in a .vswp file. For example, if the master virtual desktop has 2 GB of RAM configured and none of it is reserved then each linked clone will have a 2 GB .vswp file.

Floating (Non-Persistent) Automatic Desktop Pool

  1. Make sure the master VM is configured for DHCP and is joined to the domain. KMS Licensing is also required.
  2. Ensure Horizon Agent has the imaging component you intend to use. You can install Instant Clone or Composer but not both.
  3. Take a new snapshot of your master image if you haven’t already.
  4. In View Administrator, on the left, expand Catalog and click Desktop Pools.
  5. On the right, you can clone an existing pool. This copies many of the settings from the existing pool into the new pool.
  6. Or just click Add.
  7. In the Type page, select Automated Desktop Pool and click Next.
  8. In the User Assignment page, select Floating and click Next.
  9. In the vCenter Server page, select either View Composer linked clones or Instant clones. Select the vCenter server and click Next.

  10. In the Desktop Pool Identification page, enter a name for the pool. A VM folder with the Pool ID as the name will be created in vCenter. Also, assign the pool to an Access group to restrict delegated administration. Note: If you intend to integrate with VMware Identity Manager, then make sure you select the root Access group. Other Access Groups won’t work. Click Next.
  11. In the Pool Settings page do the following:
    1. Change the selection for Automatically logoff after disconnect to After and specify a disconnect timer.
    2. If View Composer, change the selection for Delete or refresh desktop on logoff to Refresh Immediately. Instant Clones always refresh after logoff.
    3. Scroll down.
    4. Select a default display protocol. New in Horizon 7 is VMware Blast.
    5. If View Composer, enable 3D Rendering if desired.
    6. Increase the number of monitors and resolution. This causes more video memory to be allocated to the VMs.
    7. Check the box next to HTML Access.
    8. Click Next.
  12. In the Provisioning Settings page, enter a naming pattern. You can use {n:fixed=3} to specify the location for the incremented numerals. Make sure the naming pattern does not conflict with any existing machines.
  13. Enter the maximum number of desktops to create. You can create all of them now or wait to create them as users connect. When a user connects to one of these desktops, View immediately creates another desktop (up to the maximum) and powers it on.
  14. Enter the number of spare (idle, unassigned, unused) desktops you want powered on. View maintains this number up to the maximum number of desktops. If Instant Clone, # of spare machines is only used if Timing is set to on demand.
  15. In Horizon 6.2 and newer, the maximum number of desktops per pool is 2,000. Ensure that the DHCP scope has enough addresses for the Max number of desktops specified here. Click Next.
  16. If View Composer, in the Disposable File Redirection page, select Do not redirect disposable files and click Next. Since we’re refreshing the desktops on logoff, there’s no need for a separate disposable disk.
  17. In the Storage Optimization page, if you want to use storage tiering, check the box for Select separate datastores for replica and OS disk. Click Next.
  18. In the vCenter Settings page, most of these are self-explanatory. Click Browse next to each option and make your selection.
  19. If the Parent VM is not showing up in the list then check the box next to Show all parent VMs and click the next to the VM to see the issue.
  20. For Linked clone datastores, select one or more datastores on which the virtual desktops will be placed. Select your Storage Overcommit preference. Since you are refreshing desktops on every logoff, they should stay small so Unbounded is probably acceptable. VMware recommends no more than 140 virtual desktops per VAAI-enabled LUN. If the LUN is not VAAI enabled, 64 is the maximum. Click OK when done.
  21. For Select Replica Disk Datastores, select one datastore for the replica and then click OK.
  22. Then click Next.
  23. If Instant Clone, View Storage Accelerator and Transparent Page Sharing are enabled by default and can’t be disabled. Storage reclamation doesn’t make sense for Instant Clone.
  24. If View Composer, in the Advanced Storage Options page, be aware of the following:
    • View Storage Accelerator creates digest files, which consumes disk space. Creation of the digest files requires IOPS. Make sure to set the blackout times so that this digest creation does not happen during peak hours.
    • Reclaim VM disk space is not useful for non-persistent desktops.
  25. If you scroll down, there’s a new Transparent Page Sharing Scope. The default is no sharing. Use one of the other options to enable sharing. Click Next.
  26. In the Guest Customization page, next to AD container, click Browse and select the OU where virtual desktop computer objects will be placed.
  27. If View Composer, consider checking the box next to Allow reuse of pre-existing computer accounts. Click Next.
  28. In the Ready to Complete page, you may entitle users now or later. Click Finish.
  29. To check the status of the virtual desktops, go to Catalog > Desktop Pools.
  30. Double-click the pool name.
  31. If you scroll down, the vCenter Server section has a State field.
  32. vSphere Client shows recent tasks.
  33. On the Inventory tab, click Machines (View Composer or InstantClone Details). There’s a refresh button.
  34. You can also view the status of the desktops by looking at the Dashboard.
  35. Your VMs should eventually have a status of Available.
  36. If you encounter issues with View Composer, see VMware 2087379 VMware Horizon View Composer help center
  37. If Instant Clone, the Master VM and the snapshot used by the Instant Clones must not be deleted.

vEffort explains how to use PowerCLI to create a desktop pool:

  1. Run Get-Pool > C:\Temp\Get-Pool1.txt to get IDs.
  2. Then run something like the following.
    Add-AutomaticLinkedClonePool -Pool_id UAT1 -NamePrefix "UAT1-{n:fixed=2}" -Vc_id 40263e00-123e-43481-9a05-99afg09732c3 -Persistence NonPersistent -VmFolderPath /Datacenter1/vm/Desktop Pools" -ResourcePoolPath "/Datacenter1/host/Cluster1/Resources" -ParentVmPath "/Datacenter1/vm/Reference Desktops/GOLD01" -ParentSnapshotPath "Snapshot1/Snapshot2/Snapshot3"-DatastoreSpecs "[Aggressive,OS,data]/Datacenter1/host/Custer1/Storage1" -Composer_ad_id 474cdee0-60dd-447f-bdfr-692rg3f83dbe -UseUserDataDisk $false -organizationalUnit "OU=UAT,OU=,OU=Virtual,OU=Clients" -NetworkLabelConfigFile "C:/Temp/label1.txt" -UseTempDisk $false -MinimumCount 10 -MaximumCount 10 – HeadroomCount 1 -PowerPolicy RemainOn -deletePolicy RefreshOnUse -SuspendProvisioningOnError $false -defaultProtocol PCOIP -allowProtocolOverride $false
  3. For -NetworkLabelConfigFile, see Deploy a Desktop Pool That Uses Multiple Network Labels at pubs.vmware.com.

Entitle Virtual Desktops

To make a pool accessible by a user, it must be entitled.

  1. Go to Catalog > Desktop Pools.
  2. Double-click the pool name.
  3. On the Summary tab, click Entitlements and then Add entitlement.
  4. In the Add Entitlements window, click Add.
  5. Find a group that will have permission to log into these desktops and click OK.
  6. Then click OK.
  7. For a Persistent pool, go to the Inventory tab to see the desktops. Select a desktop and under More Commands click Assign User.
  8. Find the user and click OK. Repeat to assign users to additional desktops.

Add Machine to Pool

  1. On the left, expand Catalog and click Desktop Pools.
  2. On the right, highlight an existing Automated Desktop Pool and click Edit.
  3. Switch to the Provisioning Settings tab and change the Max number of machines. Then click OK.
  4. With Instant Clones, this won’t take very long.
  5. With Composer, it might take a few minutes for the machine to boot a couple times while running QuickPrep.
  6. The pool now has new machines.

Update a Pool

  1. Power on the master/parent virtual desktop.
  2. After making your changes, shut down the master virtual desktop.
  3. Right-click the virtual machine and take snapshot. You must create a new snapshot.
  4. Name the snapshot and click OK.
  5. If you do this often, you’ll need to periodically delete the older snapshots. Right-click the master VM and click Manage Snapshots.
  6. Delete one or more of the snapshots.
  7. In View Administrator, go to Inventory > Pools.
  8. Double-click a pool name.
  9. On the Summary tab, click Push Image and then click Schedule.
  10. Or if Composer, click View Composer and then click Recompose.
  11. In the Image page, select the new snapshot and click Next.
  12. In the Scheduling page, decide when to apply this new image and then click Next.
  13. In the Ready to Complete page, click Finish.
  14. On the Inventory tab, you can click Machines (InstantClone Details) or Desktops (View Composer Details) to check on the status of the push/recompose task. Notice the Pending Image.
  15. For both provisioning methods, the snapshot is copied to each datastore.
  16. For Instant Clone, the snapshot is attached to a Replica, powered on, then powered off. Digest is then computed. Then the Replica is attached to a parent, and the parent is powered on. This takes a bit of time. But the Instant Clones remain accessible until the Replica preparation is complete.
  17. Once Replicas are prepared, for Instant Clones, each machine is rebooted once. While with Composer, each virtual machine is rebooted three times, which can be painful. Composer consumes considerable IOPS and time during Recompose operation. To speed up Recompose, switch to Instant Clones.
  18. Eventually the Pending Image field will be cleared and the desktops are available again.

Host Maintenance – Instant Clones

Since Instant Clones requires parent VMs to be running on every host, you can’t simply put a host in maintenance mode. See VMware 2144808 Entering and exiting maintenance mode for an ESXi host that has Horizon instant clones for instructions to remove a Parent VM from a host. One option is the IcMaint.cmd script included in Horizon 7 Connection Server.

Related Pages


Viewing all articles
Browse latest Browse all 594

Trending Articles