How to create a Windows 7/2008R2 Reference Image for deployment? – Part 1

There seems to be some kind of confusion on how to create reference images (or golden images, just another name). There has to be one way for each and every one, or does it.

I have decided to create a series of post on “how-to” on Ref Images and this is the first one.

Note: Yes, there is a plan to do the rest, the plan is to create a readymade deployment share with all settings done, task sequences, app wrappers, cleanup commands and all that. I’ll update this text as soon as it is ready…

What is a Ref Image?

Reference Image, Custom Image, Golden Image, well same stuff different name. It is when you take the image from Microsoft and add patches, applications and settings and then redeploy it. Now, there are some rules that must be followed and one is that the image must be sysprepped when deploying it. So that basic steps are:

  • Install the OS
  • Install Applications
  • Install Patches
  • Tweak it
  • Sysprep & capture

Seems pretty easy, but, there are a bunch of “but’s” here that is for sure. Since Windows Vista things have changed. Now what we get is an “Image”, it’s a wim file, so we do not really need to create one, we could use the WIM file as is and we also have Offline Servicing and that means that we could take the WIM file, mount it, update it with patches and save the WIM file and now deploy it and there are other real cool features that we can do, more on that later. Before we begin, there are some rules you need to follow:

The image must be sysprep:ed, otherwise it is not supported nor does it work correctly in the long run. This is NOT an option, you simply MUST sysprep the image.

The ref image should be created on a “neutral” computer system, and that means a Virtual Machine. There are two reasons here, short-term and long-term.

Short-term: Running on a VM makes it easier and faster, you can undo, test, re-test and do whatever stunt you need to. Running an a VM means that it require less infrastructure (I run my lab on my laptop).

Long-term: If you create the ref image on a new fast laptop/desktop, it will work, trust me. But you will most likely have problems later on, Why?. When you install Windows on a computer it will adjust itself to that particular model, regarding settings and drivers, some of these drivers will also install software and that is fine, well. When you capture the image you need to sysprep it first and that process is supposed to “generalize” the OS and it does. But every vendor does not really handle a sysprep the way they should. Applications that was installed as a part of a driver does not always gets “uninstalled” and that will be a problem when deploying on other hardware, vendor, version and so on. It works perfect if you want to have one image per model and per OS, but that will be like going back into the stone age.

Use Thin images as much as possible. It is much easier to add applications at deployment time instead of doing it in the image, the “only” reason I can figure to be a good reason is to save time, meaning it is much faster to install the app in ref image and the deploy the image. Well isn’t that obvious?, No, many apps are being updated so often that when ever you deploy the image there will be a new version of that app and the first thing that happens is that the old app will uninstall and then install the new version, well that takes time. So when ever you think of adding an app to the image, think twice and focus on the question “Do I really save time doing this”

Do not try to solve every problem you have, just make it work and then add more and more things you need, but first just make it work. Think versions, V1, V2 and V3. Version number one is the “look it works, almost” and version number 2 is “It works, just some minor stuff to fix” and version number 3 is “WOW, Awesome”, (in most cases I never do V3)

It should e automated, creating ref images manually takes to much time, it is boring and the “human error factor” is the biggest issue and there for it should be as automated as possible

There are some things you need: (You don’t need the trial if you already have the OS of course)

Time to prepare your Image-Creation-System

We are now going to install WAIK, MDT, create a deployment share, import OS, create a task sequence, create boot images and the  we are done. After this you will be able to boot a VM, run the wizard and select to install a Ref Image including sysprep and capture. 

  • Install WAIK using default settings (next, next, next…)
  • Install MDT 2010 using default settings (next, next, next…)
  • Using Deployment Workbench – Right click on Deployment Shares and select
    • Create a Deployment Share
    • Location  = C:\MDTBuildLab
    • Share Name = MDTBuildLAB$
    • Share Description = MDT Build LAB
    • Click next on rest of the questions…
    • image
  • Using Deployment Workbench – Right click on the Operating system node and select “Import Operating system”
    • Browse to the DVD for the OS and import it using default settings
  • Using Deployment Workbench – Right click on the Task Sequences node and select “New Task Sequence”
    • Task sequence ID = RW7X86 (if the ref image is going to be Windows 7 x86 as an example)
    • Task sequence name = Ref – Windows 7 x86
    • Task Sequence Template = Standard Client Task Sequence
    • Operating System = Select Windows 7 x86 (if that is what you want)
    • Do not specify product key
    • OS Settings
      • Full Name = A name
      • Organization = A Org
      • Home page = Any
    • Do not specify the local Administrator Password
  • Right click on the task sequence you just created and select properties and enable Windows Update (It is disabled by default)
  • Using Deployment Workbench – Right click on “MDT Build LAB” and select “Properties”
    • On the Windows PE x86 settings and on Windows PE x64 Settings
      • Check – Generate a Lite Touch bootable ISO image (This way we will be able to boot the VM on a ISO image and that is MUCH faster then booting over PXE)
  • Using Deployment Workbench – Right click and select update and wait

Done, we are ready to install a ref image. Create VM in Hyper-V, VMware or whatever you are using, attach the ISO file (They are in the C:\MDTBuildLAB\Boot folder, be sure to use the correct ISO. The x86 will only install X86 OS and x64 will only install x64 OS)

Next time I will spend more time on how to automate the process


Categories: Uncategorized

16 replies »

  1. Great post! Would you say there are any scenarios when you DON’T use reference images and just the normal MDT OS deploy? Let’s say you have MANY different client hardware and there is quite a few different configurations with different apps on many PCs. Or should you always use a very “empty” reference images for the primary reason it’s faster to deploy?

  2. Thanks for this, it’s helping.

    I can’t understand how you can take an image from Windows Deployment Services, modify the task sequence, then put it back into WDS again… For example to just add a task or feature to an already captured object.

    Any chance of a quick example?

    • WDS or Windows Deployment Services is not used for anything other then PXE booting. WDS is not “complete” so we need MDT to deploy things. This post was just about the creation of the ref image. When the image is captured I use MDT/SCCM to deploy the OS and WDS does play a part in that, it will boot the WinPE image using PXE.

  3. Curious if you have any more posts plan for this series on reference images. I found this one dead on as I prepare my Windows 7 Image for the fall semester (I work in higher ed).

  4. Hi Mikael
    This is a great site and i have followed most of your suggestions when setting up our own MDT-service.
    I have one problem though with this topic…

    When i add the refimage to be used as the installimage in the production enviroment i always get an error…

    The installation can’t be done as it is missing the setup.exe…
    There are three choices you can make when adding the image : no setup/sysprep files, copy vista or copy xp setup files.

    This guide would really benefit from completion and i would just love to finish my MDT-setup using it.

    How do i solve my issue? Have i missed the conclusion of this article or is it still missing?


    • Yes, you “missed” that when you import the custom OS you must also import the setup files, since MDT 2010 use setup.exe it needs it to be able to install the OS, just re-import the OS once more and then edit the tasksequences and you are ready to go

  5. Mikael, I’m a huge fan as of today! I’m glad to have come across this site. Thanks for the clarity of instruction! Can’t wait for part 2!

Leave a Reply to David Cancel reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.