Jesse Boehm - Information Technology Consultant

If you are looking for we are currently closed for Interface Work.

Please contact Jesse for IT Consulting, Web Design, Online Marketing and Graphic Design.

This site is currently serves as Jesse's Resume & Article site

Creating an Optimized Golden Image of Citrix XenApp 7.6 on Windows 2012 R2 with Citrix Provisioning Services 7.6

by – Jesse Boehm

V1.1 – Addendum

Changes in this Version

Addendum V1.1 is in thanks to: Carl Webster (@CarlWebster), Joe Shonk (@joeshonk) & Cláudio Rodrigues (@crod)

A PDF Version of this Article is available for $5.00

Changes Made:

  • Change SCSI Controller
  • Changed Write Cache Type
  • Booted Server and Checked Write Cache Partition
  • Updated my Master Template with the new Hardware Settings

Change the SCSI LSI Logic SAS Controller to a VMware Paravirtual Controller

Changed Write Cache from “Cache on Device Hard Drive” to “Cache in Device Ram with Overflow on Hard Disk”

Set Maximum Ram Size to 2 Gig (2048 MBs)

Added an Additional 2 Gig of Ram to my Base VM Image to cover that 2 Gig of Ram added in the Cache to Device Ram with Overflow on Hard Disk Write Cache Setting.

For the purposes of this article I have left my CACHE Hard Drive at 16 Gig but Hard Drive sizing is based on what you want to persist. App-V Cache, Logs, AV Files, Etc. anything you wish to persist.


After making these Hardware changes and booting the Master Target Device I had to reinitialize the D:\ Partitiion and the E:\ Partition and then shutdown the server. Changed the vDisk to “Cache in Device Ram with Overflow on Hard Disk” with “2 Gig of Ram” to test everything.

This Is what the boot screen looks like

Write Cache: Enabled: HD VHDX Differencing


This is what D:\ Partition looks like now:

Update your Master Template for Provisioning.

I will update the Core Document with these changes as soon as possible but will leave Addendum V1.1 at the top of the article for immediate viewing.


Creating an Optimized Golden Image of Citrix XenApp 7.6 on Windows 2012 R2 with Citrix Provisioning Services 7.6
by Jesse Boehm

V1.0 – Addendum

This article is to help create a guideline for creating Citrix XenApp 7.6 Published Desktops and Application Servers that can be deployed using Citrix Provisioning Services 7.6.

When I went looking for information on how to do this and best practice I found no information. So this article and guidelines are what I have built based on hours of research and testing in my LAB for best performance, boot times and automation using Provisioning Services 7.6.

I will be continuing to update this article.

Facts about this document:
Hypervisor: VMware VSphere 5.5
Citrix Products:
Citrix XenDesktop and XenApp 7.6
Citrix Provisioning Services 7.6
Write Cache: Cache on Hard Drive (Local Storage)

XenDesktop and XenApp 7.6 Farm
XenApp Server Operating System: Windows 2012 R2
All Windows Updates Installed

I have Classic Shell installed to bring back the Classic Start Menu. My End Users don’t like change and I want to deliver a Desktop that looks as close to what my users have been using for years. You can call that antiquated. But that is just me. You can ditch it, but I love it. For administrators you can turn this off. For default profiles you lock this down completely. No more Metro Theme.

VM Template: This is the Template I am using in my LAB Environment, this guide is not a sizing guide. This is just what I like in my LAB Environment.

Create VM
4 Gig of Ram
2 vCPU VMXNET 3 Network Adapter (This is VMware VSphere Specific Requirement)
OS Hard Drive: 60 Gig
Add Additional Hard Drive 1 (16 Gig) (Write Cache: Cache on Hard Drive)
Add Additional Hard Drive 2 (24 Gig) (Page File, Print Spooler & Event Logs)
No Floppy

NOTE: The order of adding the two additional drives is important. I will explain why later in this article.

Hard Drive 1: This drive is going to be used specifically for Write Cache with Provisioning Services. This Drive needs to be ADDED FIRST so that when you later make a Clone to Template of the Master Image for Deployment of the XenApp 7.6 Servers it automatically selects Hard Drive 1 as the Write Cache Hard Drive. This will save you time later. It is fixable, but if you do this step now, you won’t have to worry about it for the rest of this process.

This will also be the D:\ Drive. I am making this a 16 Gig Drive for my LAB, this should be sized based on your needs. But 16 Gig gives you a lot of room for Write Cache. I am using Local Storage. There are many Write Cache Options. Performance wise in my LAB this gives me the best performance.

Hard Drive 2: This drive is going to be used specifically for System Usage that I want to keep off the Master vDisk. I will configure this drive which will be my E:\ Drive to host my Page File, Print Spooler Files and Event Viewer Files. I can also stash files on here like Scripts, copy of the Default Profile, Backup of the Master Start Menu. Whatever you need.

This is also Local Storage in my LAB setup.


I realize Local Storage may not be the best option for everyone and all environments for Hard Drive 1 and Hard Drive 2 but this is what worked for me. I don’t have access to a SAN to test that out. This is a guideline to what I have found what works for me and provides me the best performance and fastest boot times.


Deploy Virtual Machine with the specifications listed above.

Boot the server and as soon as you login do the following.

Change the CD Rom Drive Letter to X: or something else that you will not use with Home Share’s, Mapped Drives, Client Mapped Drives, Drive D:\ or E:\. I am making it X:\ as I will never use that Drive Letter. All of these Drives will be hidden later via GPO as well from the End User.

Install VMware Tools

Then Restart the server when prompted

Add the Server to Domain – Do not add the server to the Domain with the name that you are going to want to name your Master XenApp 7.6 Image that will be added to the Domain.

Install Citrix Virtual Desktop Agent. Now I choose the XenDesktop Option as opposed to just the XenApp option here on the VDA Agent as I will be delivering Published Desktops and Published Applications.

I have found that after the First Install Component the server need a reboot to proceed with the install. So let the server reboot.

When it comes back up login the setup app will launch and you will have to say OK to proceed.

The install will continue and finish installing all components.

When that is done it will give you the option to Restart.



Install Citrix Provisioning Services 7.6 Target Device Installation.

When Install completes it will ask you to Make Image…

Enter the IP of your Provisioning Services Server

Select Create new vDisk

Enter vDisk name

Enter Target Device Name: This is going to be the name of your Master Image XenApp Server. This name will be Active Directory. So choose the name you want this to be in Provisioning Services and in AD for future purposes.

Here you are configuring the Image Volumes. We are dealing with the C:\ Partition and System Reserved. This image does not represent the 60 Gig Partition I am using in my LAB (I forgot to take a screen, so this was taken after the fact ?

Summary of Farm Changes and everything we just configured. We are going to click on Optimize for Provisioning Services.

Here you can use the Provisioning Services Device Optimization Tool to optimize your vDisk. Based on this Article by Robin Hobo

How to create a Citrix XenApp 6.5 vDisk

After installing and configuring Citrix Provisioning Services Server (as described here) and the Citrix XenApp 6.5 Controller (as described here) it’s time to create the Citrix XenApp vDisk, also known as the “Golden disk”, for the Citrix XenApp 6.5 running in Session-host mode only. It is highly recommended to use Citrix Provisioning Services when deploying multiple XenApp servers in your farm (hardware must be equal). With Citrix Provisioning Services you can provide a single vDisk for all your XenApp servers. Booting all the XenApp servers from the same vDisk ensures that they all are equal, and since the vDisk is read only, all servers will be in “original clean state” after a reboot. With that in mind, consider well what you install or configure in the vDisk because it will be present on each XenApp server booting from that vDisk. Additional steps should be taken for some software, for example software that’s need a unique ID or GUID. Also think about the software licenses. In this step-by-step guide I will create and configure a Citrix XenApp 6.5 vDisk and I’ll give you some tips which you should be aware of. For this case I will use XenApp servers which have a local hard disk for the PVS cache files and some redirections (like the Windows paging file). Step 1 – Creating and installing the “Master server” Create a XenApp Master server, this is a server that have equivalent hardware specs with the other servers and will be used to create the Citrix XenApp vDisk. Configure this server to boot from network first. Install Microsoft Windows Server 2008 R2 with all necessary updates and patches and join the

I followed the recommendations in this article on what to disable. But you should choose the settings that you think work for you

Click Finish

You will now be Prompted to Reboot Now. Say NO. As if you just reboot most likely your server will just reboot if it is a VM quickly to the Hard Drive.

Click NO again.

Shutdown the server.

Go to the Options Tab then Boot Options and check the Force BIOS Setup check box and click OK.

Change the Boot Order to boot to the Network and then the Hard Drive. F10 to save the changes and then Reboot the Server.

Next Reboot you should PXE Boot to the Provisioning Services Server and get a DHCP Address

Connected to Provisioning Services Servers. You can see the Client Computer Name is now the Master Image/Target Name you set in the Imaging Wizard.

Login to the server with the same credentials as you ran the Imaging Wizard with and the Snapshotting will start.

Then the Copying of the Hard Drive will start to populate the vDisk.

When Finished click OK and it will bring you to the Server Desktop. Shutdown the Server.

Remove main Operating System Hard Drive, Don’t Delete it. You may need it at some point.

Switch Master Server to boot to vDisk

Next step here is to Create a Machine Account for the Base Image. In the PVS Console Right Click the Server, choose Active Directory and then Create Machine Account.

Select the OU where you want to create the account.

If you already have GPO’s created for XenApp Servers. Don’t put the server in that OU. Put this in its own OU for the Build so no policies gets in the way.

Now we need to switch the server over to boot to the new vDisk we created. In Provisioning Services right click the Target Device and choose Properties and change Boot from Hard Disk to vDisk.

Click Ok and Boot the server and your new Target Image should come online and boot from the vDisk.

First Boot

First Boot – Provisioning Services Connected

First Boot – Success


We have now created our master Windows 2012 R2 vDisk with XenDesktop Virtual Delivery Agent 7.6 Installed on the server and provisioned the Hard Drive to do a vDisk and created a Master Target Device.

There is one more step I like to do for my build since I am going to deploy a D:\ Drive for Write Cache and E:\ Drive for System Files. We need to Initialized our Hard Drive 1 and Hard Drive 2

Initialize Disks

Initialize hard drives online

Make 16 gig drive D:\ Drive (Label CACHE or whatever you want)

Make 24 gig drive E:\ Drive (Label it SYSTEM or whatever you want)


This is what my finished Hard Drives look like once configured and Initialized.

We are going to have to make some changes to the E:\ Drive later and modify the Template and I may change this step in the future. But at this point this is where I shut down my server and Clone to Template the server and make my Virtual Machine Template for creating XenApp 7.6 Servers Later.

Shut server down and Clone and make Template for master Template Deployment. I do this here as I want the D:\ and E:\ Drive as part of my Template and in my Base Image Online and Initialized. Obviously there are many ways to do things. But this is my preference from an automation stand point and then Cache on Hard drive Standpoint I am going to use when deploying my XenApp Servers.

This takes us through creating our Master Template: Step 1

Build Core Image

I create a Maintenance Release in PVS here as I did all this prep for a clean image. Encase the next step bombs I want to be able to revert.

In PVS set the vDisk to Standard.

Right-click select Versions, choose New

This will create Version 1 Maintenance Release

Next we need to set the Target Device to use the Maintenance Release. Go to your Target Device in y our Device Collection. Right-click the device and select Properties and change Type from Production to Maintenance.

Now it is time to boot the VM. When the VM boots this time it will have a Boot Menu

Select option 1 to go into Maintenance Mode which is what we just configured in the previous steps.


We are going to use the Awesome Script. You can read about it here

It was created exactly for what we are doing here and that is creating an Optimized Golden Image for Citrix XenApp. The script itself in the link above article I could not download. I found the script from another source. I had to make a change to the script for 2012 R2. I had to remove 4 lines of code. I had issues with the System Restore Portion so I removed lines 267 – 272.

You can download the Original Script (awesome.vbs) and the Modified Script (everythingisawesome.vbs) from the link on my website below.
Copy the everythingisawesome.vbs Script to your server desktop

Run Awesome Script from Citrix If you want to. Depends on if you want to go with controlling everything via GPO or not. I would recommend reviewing each setting and then commenting out what you don’t want to use in the script. I think it is a huge time saver. Don’t run this script before you snapshot or you will run into errors. I like it as part of my base vDisk

But you should definitely review this script and decide what is good for you, if it is good at all and whether you want to lock this down at OS level or use GPO. For my article I am doing this at the compute level in my lab.

Read this Article Here

Note: After running the script, a reboot is needed in order for the script registries to apply properly. As with any script, we highly encourage understanding what the script does prior to running it. Citrix nor the authors are liable for any issues that come as a result of running this script so please make sure to make backups of your registry and make a MAINTENANCE RELEASE encase something goes wrong.

Delete the everythingisawesome.vbs Script from the Desktop. Or keep a copy of it in the E:\SCRIPTS Folder you can create just to stash it. But you can delete it. But I like to build an Arsenal of tools. Not a bad to have things on your Golden Image.

Reboot back into maintenance mode just to check everything comes back up right.

Server comes up, everything looks good, shut it down.

Everything Is Awesome!


Back into PVS, here you have multiple options.

You can go back into Versions for the vDisk and Select Version 1

You can put the Maintenance Release into Test Mode or into Production Mode. I am going to put Version 1 into Production Immediately.

Now Version 1 has the green check mark.

Click Done.

Then right-click the vDisk and select properties and put the Access Mode into Private Image Mode.

You can also Delete you Base, but I am going to keep that around for now. The beauty of Provisioning Services. Instead, I am going to Promote my Maintenance Version. Right Click your vDisk go to Version, Select Version 1 and click Promote

Go back to your master image and set it back to Production and boot the server.

Boot your server

Now to make the Golden Image.

Steps I Follow for my golden image.

Turn on Hidden Files for this process. I need this. This will be turned off in the Default Profile.

Go into Advanced Settings, change everything for Best Performance.

Change Page File to the E:\ Drive, I like to make it 16 Gig or (16384 Static), Delete the Page File from the C:\ Drive. I leave the rest of the drive for Print Spooling and Log Files

Go to Printers > Printer Properties > Advanced, Change Path to E:\PRINTERS

Create folder E:\EVENTLOGS

We are going to do the redirection via GPO later, not in this article. But the path to the log files on 2012 R2 is:


I like to clear the log files now before I take the files. So when the GPO takes affect later they are clean and start fresh.

Need to Stop the Windows Event Log Service

Go to Logs file path and copy log files to E:\EVENTLOGS (System, Setup, Application & Security) and copy them to E:\EVENTLOGS\

Start the Windows Event Log Service

You will need to give Full Control to the NETWORK SERVICE and Event Log Readers Local Service Account to the EVENTLOGS Folder.

You will change Path of Log Files by GPO Computer Policy Later.

These Admin Templates settings are found under Computer Configuration\Policies\Administrative Templates\Windows Components\Event Log Service


Disable TCP Offloading

Step 1: In the Windows server, open the Control Panel and select Network Settings > Change Adapter Settings.

Step 2: Go to the Advanced Tab

Step 3: Disable each of the following TCP offload options, and then click Ok:

  • IPv4 Checksum Offload
  • Large Receive Offload
  • Large Send Offload V2 (IPv4)
  • Large Send Offload V2 (IPv6)
  • TCP Checksum Offload V2 (IPv4)
  • TCP Checksum Offload V2 (IPv6)

Step 4: Restart the Server

We need to enable Roaming Profiles. This can be done at the GPO level so I will give instructions for both. For this document I am going to do it via registry in my Golden Image

We need to create the following registry entry


Use Registry Editor or Group Policy to create the following registry key DWORD Value and set it to 1

Then Reboot

Let the server come up with a clean boot.

My E:\ Drive now looks like this

At this point you can check your User Profiles and if there any other profiles you can clear them out.

Nice and clean.

This is our Optimized Golden Citrix XenApp 7.6 Base Image.

Shut the server down.

Time to update the E:\ Partition in our Master Template. This is why I mentioned earlier that we would be touching the Template again. I want all these changes that I made to the E:\ Partition to be deployed with all my PVS XenApp 7.6 Servers later.


Now I made Changes to my E:\ Drive Partition that I want to be in my master Template. So we are going to do a few final steps to update the Clone to Template we made earlier.

Covert the Template back to a VM

Delete the 24 Gig Partition, you can just delete this permanently

Now edit your settings on your Base Image and take note of the file name of your E:\ Partition. Remove this partition but DO NOT DELETE IT.

Now we are going to Copy the E:\ Partition *vmdk file from the Production VM Folder.

And Paste it to the Template VM Folder

Once the copy is complete, we can add Hard Drive to the template and select the Hard Drive we just added.

Save that configuration. And convert the VM back to a Template.

We also have to reattach the Hard Drive to our Production VM in the same way


Boot the Server once to make sure everything looks good.

Everything looks good shut the Master Target Device down.

We are done. Target Device Master is COMPLETE.

Now in preparation of making a Golden Image vDisk that will be my permanent base image before any Applications are installed I am going to Merge Version 0 and Version 1 into a single Version.

Go back into version and select Merge

Merge Base and Set Merge Version to Production.

Now in a REAL WORLD environment you may not follow this exactly…

Click Ok.

Message you get, say OK and the Merge has begun.

Merge is Complete. Now were are going to Delete Version 0 & 1

Merged Base – Done!

The Golden Image

You have now Made this Master vDisk. So it is time to copy this vDisk and make a Golden Image of your pristine XenApp 7.6 Core OS Base.

How to Create a New vDisk from an Existing vDisk

Step1: Copy the PVP, VHD & LOK Files from your current base vDisk Image. The LOK file is blank and the vDisk is not locked, I verified this. But I copy the file anyway to be safe.

Step 2: Export the vDisk from the PVS Console

Step3: The Export created an XML file in the STORE Directory. This file is going to be renamed to whatever you are to call your new vDisk Golden Image. This name will be the same name you will rename the files copied in Step 1 once the copy is complete. Example XENAPP76vDiskSOLIDGOLD.xml

Step 4: Rename the copied PVP, VHD & LOK files to the new vDisk name.

Open the XML file and make these edits

It now looks like this

Step 5: Import the Golden Image vDisk into Provisioning Services

Click Search, and there is our Solid Gold Image

Click Add and then Close.

Your new Golden Image vDisk is now in your vDisk List


So now what? Let’s boot that up with some adjustments to the vDisk

I am going to let it come up in Standard Mode so I can see the Write Cache kick into the Hard Drive.

Then on my Master Target Device I am going to change the vDisk for this single boot.

Boot the Server

Write Cached – Cache on Hard Drive Enabled

Now I want to look at one more thing

Login and look at the vDisk Status

Shutdown the server.

Change the vDisk on the Target Device back to Master vDisk. Keep your perfect Golden Image to the side for clean install when you need to deploy Alternate deployments.

Now you are ready to start building out your Applications, Default Profiles and making the server End User Ready.

This is creating an Optimized Golden Image of Citrix XenApp 7.6 on Windows 2012 R2 with Citrix Provisioning Services 7.6 by Jesse Boehm

Articles and Links that helped me create work through and document this process.

There is nothing out there when I started searching so I had to pull from many resources to compile what I consider the Best Practice for Making a Citrix XenApp 7.6 Golden Image to be Deployed with Citrix Provisioning Services 7.6.

logo image
Follow by Email
Visit Us