Archive for VDI

VMware View 5.1 SSL Certificates

With the release of VMware View 5.1, the use of SSL certificates on your connections servers has become a requirement. There are ways of avoiding the use of SSL certificates for the View connections servers, however in the nature of security this isn’t recommended. In View 5.1 the process of changing the SSL certificate on your connection servers is much simpler than in previous releases as i will demonstrate in this article.

Assuming you have generated or purchased a trusted certificate with the relevant common name, and friendly name of “vdm”. Open an MMC console on your connection server and add the Certificates add-on then select to open Local Computer. Navigate to the Personal folder then the Certificates folder where you will find the default self assigned View connection server certificate. This is the one we want to replace so right click the certificate and select delete. Once this has been deleted, highlight the Personal folder, right click, select All Tasks, then click Import. Import your trusted certificate and should see it appear under the Personal/Certificates folder.

Providing you have generated your certificate correctly with a friendly name of vdm (this is most important), open the Windows Services console and restart the VMware View Connection Server service. This will assign the new certificate to the connection server. Once the service is back up and running, try browsing to the admin page of the connection server by the common name of the certificate to verify the certificate has changed, for example view.contoso.local/admin. If your running Internet Explorer you shouldn’t receive the a certificate warning with the red bar at the top of the page.

Once you have confirmed the new SSL certificate is being used by the connection server, log in to the View administrator console and navigate to the Server options under the View Configuration tab. Locate your connection server and click edit, in the connection server properties under the General tab you will see HTTP(S) Secure Tunnel, make sure you set the External URL to the common name of the new certificate. In this case view.contoso.local.

If all has been configured correctly and your certificate is trusted, on the View administrator dashboard you should see the service status of the connections servers as green.

VMware View 5.1 Storage Accelerator

With the release of VMware View 5.1 a number of new features have been introduced, particularly around storage performance. For me, the key feature is the View Storage Accelerator, or you may hear it referred to as Host Caching.

Without going into intricate detail, the storage accelerator basically creates an additional file within the datastores for the replica disk and all linked clone OS disk. This file is know as a digest file and is used as a caching mechanism. The way this digest file increases performance is by minimising the amount of read requests back to the replica disk. This is done by caching commonly read blocks from the replica disk into the OS disk digest file which can be read directly acting as a cache. This can help minimise boot and log on storms within your View environment.

Enabling the Storage Accelerator is relatively simple and can be achieved by following the below steps.

Step 1. Log in to you VMware View administrator console, under View Configuration click servers. Locate your vCenter server and click Edit.

Step 2. Click on the Host Caching tab then check the Enable host caching for view check box. This will enable the caching capability and allow you to specify the size of the cache for all, or individual hosts. The minimum cache size is 100MB with a maximum of 2GB. Click OK to apply the change.

Step 3. Locate a linked clone pool you want to enable the storage accelerator on and Edit the settings. Click on the far right tab named Advanced Storage and check the Use host caching check box. Click OK to apply the settings.

The storage accelerator features is now enabled for this linked clone pool, and will require a recompose to generate the necessary digest files. Hopefully you will now see a performance increase on read intensive operations.

Thanks for reading.

Optimise Windows 7 for VDI

There are a number of options and settings that can be tweaked withing Windows 7 to increase its performance and reduce its storage I/O. This is particularly useful when planning on using Windows 7 in a VDI environment as it can decrease the overhead and storage impact of multiple VMware View session.

VMware have released a recommended configuration guide to optimise Windows 7 for VDI as have many other bloggers. To combined this collected set of recommended Windows 7 tweaks, I have published both a script and registry files that can be used on a base Windows 7 virtual machine before you begin to either deploy, or clone for use with VDI.

The script and registry files are to be used together to invoke the necessary changes. Once applied, the changes will be reflected on all post user profiles created. Follow the below steps on how best to apply these optimisation settings.

Step 1. Create a new Windows 7 virtual machine and login as a local administrator.

Step 2. Run the following registry files that can be found here. Reg1 | Reg2

Step 3. Run the following batch script that can be found here. Script

Step 4. Continue by cloning this virtual machine or test its effects by logging in as a general users.

By using these optimisation teaks, I found the I/O impact on my VDI environment had reduced as well as an increase in refresh rate during a View session for users at remote locations.

Thanks for reading and be sure to check out my other posts on VDI and Windows optimisation.

VMware View Enable Display Settings

When connected to a VMware View session you may have noticed that you do not have access to change any display settings. This can be a problem for users that have a large monitors  as View auto sets the desktop resolution for best clarity. In my experience, I have had users complain about how small icons and text are shown within their View session which at the time I didn’t have a solution for.

Thankfully, VMware have bundled a group of ADM templates containing many options for tweaking View components such as the View agent and PCOIP parameters.  You can fine these ADM templates on any one of your connection servers in the following location.

C:\Program Files\VMware\VMware View\Server\extras\GroupPolicyFiles

Once you have created a new GPO and loaded these ADM templates into your group policy manager, navigate to the following policy.

Computer Configuration > Administrative Templates > Classic Administrative Templates > VMware View Agent Configuration > Agent Configuration > Toggle Display Settings Control

To enable the use of the Windows display settings, you need to disable the Toggle Display Settings Control.

Equally you can add the below registry key to a logon script to achieve the same result.

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System] “NoDispCPL”=-

Thanks for reading.

VMware View Scheduled Recompose

In this post we’ll go over writing a View PowerCLI script to schedule a recompose of a desktop pool.

If your like most VMware View administrators you’ll probably use linked clones, and know that now and again these clones will need recomposing to keep up to date with operating system patches or updates for embedded applications. If your organisation is like mine and operates on a 24 hours basis, getting downtime to perform a recompose can end up being headache and is usually scheduled for a unsavory hour.

Unfortunately scheduled tasks was not part of the View v5 release which i imagine left many people in my situation slightly disappointed. To get around this need for functionality, i turned to the View PowerCLI extensions and wrote a script to perform my desired tasks.

Below you will fine my script, along with one of my working examples that allows you to specify a linked clone pool to be recomposed from a specific virtual machine and snapshot at a defined time and date.

 

Script: Get-Pool -pool_id your-pool-id | Get-DesktopVM | Send-LinkedCloneRecompose -schedule ‘yyyy-MM-dd-23 hh:mm’ -parentVMPath “your-parent-vm-path” -parentSnapshotPath “your-snapshot-path

 

Example: Get-Pool -pool_id LC-EXT-H2F | Get-DesktopVM | Send-LinkedCloneRecompose -schedule ’2012-01-23 11:42′ -parentVMPath “/Hangar 1/vm/VMware View/Linked Clones/viewpocmlc” -parentSnapshotPath “/Base Windows 7 Image/Base Windows 7 Tweaked/Windows 7 with Basic Apps”

 

Below is an example desktop pool’s options which details the paths for -parentVMPath shown under Parent VM, and -parentSnapshotPath shown under Image.

Thanks for reading and be sure checkout how to schedule the refresh of a desktop pool Here

VMware View Scheduled Refresh

In this post I will detail how to make use of the VMware View PowerCLI extensions. One feature I has hoping to see in the release of VMware View 5 was the ability to schedule tasks such as refreshing desktops or recomposing entire pools. Unfortunately this feature wasn’t added to View so i seeked my own solution. With View PowerCLI you can perform most if not all main functionality and better still, schedule when you went these commands to run. In this post the relevant commands for scheduling the refresh of a pool at a defined time are outlined.

Script: Get-Pool -pool_id your-pool-id | Get-DesktopVM | Send-LinkedCloneRefresh -schedule ‘yyyy-MM-dd hh:mm’

Example: Get-Pool -pool_id LC-EXT-H2F | Get-DesktopVM | Send-LinkedCloneRefresh -schedule ’2012-01-23 09:12′

Apply Windows Visual Effects Automatically

In this post we will be discussing the Windows visual effects under the performance settings and how to automatically apply them. Windows performance settings allow you to tweak the visual aspect of your desktop to either improve it visually or speed up its performance. If you aren’t aware of these options, click right on Computer and select Properties, click Advanced Setting, under the Performance section select the settings button as shown below.

Q1. Why would you want to change these setting?

A1. In my case I use these setting to increase the performance of a VDI session over high latency Internet links. Disabling these options reduces how much is refreshed on the screen when receiving a PCOIP connection from VDI remotly.

Q2. Why would you want to automaitly set these options?

A2. As mentioned, VDI is my main use for these options and unfotunanlty you cannot pre define these option on on a per desktop basis. These options are reflecedt on a per user basis meaning if i login to a machine and turn off all visual effects options the log out. The next person that logs in will also have to set these options as there are defined in the users local profile. unfortunanly redirected profiles do not carry these options.

As with a VDI enviroment you cannot expect every user that logs on to modify there own settings for best performance, i needed a way to automate this. To do so i created two registry files that apply the correct setting on logon and log off. Sadly not all optiosn apply from a simgle execution of thye script.

The way i managed to do this was by creating a batch scprit to pull the registry files from a file share and apply them through a login script assigned in group policy. Simple but effective.

 

Registry files: Download Here

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\VisualEffects] “VisualFXSetting”=dword:00000003

[HKEY_CURRENT_USER\Control Panel\Desktop] “UserPreferencesMask”=hex:90,12,01,80,10,00,00,00

[HKEY_CURRENT_USER\Control Panel\Desktop] “DragFullWindows”=”0″

[HKEY_CURRENT_USER\Control Panel\Desktop] “FontSmoothing”=”0″

[HKEY_CURRENT_USER\Control Panel\Desktop\WindowMetrics] “MinAnimate”=”0″

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System] “NoDispCPL”=-

 

Batch script: Download Here

REGEDIT.EXE  /S  \\yourfileserver\share\VisualFX.reg

 

How to apply: Once you have you batch script and registry file, place them on a file share where all users have atleast read access. Enter group policy manager for your domain and create a new GPO. Edit the GPO and navigate to the following:

User Configuration  > Windows Settings > Scripts (Logon/logoff). Double clike this item and click Add then enter the path to the batch script including its extention. See below for me detail.

I would rcomment adding this as both a logon and logoff script to minimise the number of logins a user has to perform. With both logon and logoff set, a single login / logout will fully apply the changes.

Thanks for reading and remember to lookout for future posts on perfromance tweaking.