You are here:   Research
  |  Login

Welcome to my blog, quickest way to find articles is usually to search for them.

Search in All Title Contents

Building reference images like a boss!

May 14 2014

It’s a great week here at TechEd 2014 in Houston, later this afternoon I will present the never-dying “Creating the perfect reference image” with my partner in crime (and good friend), Mikael Nystrom. If you ever attended one of my deployment sessions before, you know I recommend using MDT Lite Touch for most scenarios, but what if you want to speed up the process?

All in all, by following these tips you can speed up the image capturing process by about 400 percent :)

Tablet pc with text Like a Boss with beach background 

Free Resources

If you haven’t created reference images with MDT before, check these Microsoft resources:

Microsoft TechNet guide: Create a Windows 8.1 Reference Image

Microsoft TechNet Virtual Lab: Creating a Windows 8.1 reference image

TechEd 2014 video: Building the Perfect Windows 8.1 Image 


Make the image smaller by deleting setup files for already installed updates

Mikael Nystrom ( has created a nice VBScript for some cleanup operations, including running the DISM.exe /online /Cleanup-Image /StartComponentCleanup /ResetBase command – Effectively shaving of about 1 GB of the image size. Simply add the script as an application, and configure your task sequence to run it before sysprep. You can download the script from his post:

A Windows Server 2012 R2 reference image, fully patched, with and without cleanup.

Make sure ALL updates are installed into the reference image

Because of an issue with the ZTIWindowsUpdate.wsf script, not all updates will be installed during build and capture. There reason is that some updates actually have to be reinstalled, and the script logic prevents that. The workaround is simply to reset the updates list in between the two Windows Update actions. Alexey Semibratov and Keith Garner came up with a simple workaround back in the MDT 2010 days that still is valid for MDT 2012/2013.

ZTIWindowsUpdate.WSF does not install all patches

The script from Alex and Keith added to a Windows 7 task sequence.

Note: Mikael Nystrom also posted an updated version of the script that includes logging here:

Bump up the speed using a VM with multiple vCPUs

Capturing a 4 GB image with MDT typically takes 40 minutes on a virtual machine with 1 vCPU, but only 25 minutes when assigning 2 vCPU’s.



Bump up the memory to at least 4 GB

Windows 7 currently has quite many updates (almost 200) that needs to be deployed, so many in fact you may run out of memory. Settings the VM memory to 4GB solves that problem.

Update the Windows Update agent

Make sure that the latest Windows Update agent (currently July 2015) is installed by the task sequence before the Windows Update action. Here is the link: 

Bump up the speed using DISM instead of ImageX

Of the above numbers, when using MDT with the default scripts to capture Windows 8.1 and Windows 10, about 15 minutes is used just scanning the file system (bug in ImageX which MDT is using). You can use DISM instead, which is much faster, see be below post by Mikael. This is not needed for build and capture of Windows 7, but since DISM works for Windows 7 and Windows 8.1/10, it makes sense to make the change anyway.

Nice to Know – Switch from ImageX to DISM in MDT


Bump up the speed using a RAM disk

If you already have SSD’s in your Hyper-V or VMware Hosts, you won’t gain to much speed from this tip, but if you have SAN disks, or local 10k/15k disks, you can shorten the build and capture time quite a bit by deploying the VM to a RAM disk instead. Pretty good number of IOPS, and transfer rates :)

In my environment I use the free RAM disk from StarWind ( ). Simply create a 20 GB RAM disk, and then create your VM on it.

Note: Don’t let the StarWind app format the disk, do it yourself from disk manager or server manager after the RAM disk is created. I run into weird issues when StarWind was allowed to format the disk.

The 20 GB RAM Disk created.

The RAM disk in File Explorer.

Happy deployment, and thanks for reading!
/ The Deployment Research team

Ami Casto

Johan Arwidmark

Blog Archive