I created a new virtual machine on my Hyper-V server, installed Windows Server 2008 R2 Enterprise Edition, enabled Windows Deployment Services – and fell in love! Windows Deployment Services is surprisingly easy to setup and very powerful. I am now kicking myself for not doing this ages ago!
With Windows Vista / Windows Server 2008 and later Microsoft has moved to a new OS installation model (actually – this model was enabled for Enterprise customers with Windows XP and Windows Server 2003 – but Vista made it mainstream). This model is one where we use Windows to install Windows. Specifically we use a special light weight version of Windows to install the full version of Windows.
This light weight version is WinPE (Windows Preinstallation Environment). When you boot a Windows Vista or later install DVD you are booting into a version of WinPE. From there you configure your physical hard disk and lay down the full installation of Windows.
If you look in the “Sources” directory on an installation DVD you will see two .WIM files. BOOT.WIM is the WinPE image that is booted off of the DVD. INSTALL.WIM is the Windows image file that is applied to your computer to install Windows.
This concept of having a boot image and an install image is key to understanding how Windows Deployment Services works.
Now, back to the story. Before I tackled the “XP on my netbook problem” I thought I would try getting generic “Windows 7 installed over the network” going – as I figured this would be the easier problem to solve. Was it ever!
After enabling Windows Deployment Services – I pretty much just put my Windows 7 DVD in the virtual machine and said “use the bits off of that”. Windows Deployment Services:
- Copied the appropriate files off of the installation DVD
- Automatically configured boot images and install images
- Automatically configured boot menus
- Automatically configured my DHCP server to point to it for network boot (keep in mind that I am running in a Windows Server 2008 R2 domain with a Windows DHCP server)
All-in-all it took me about an hour to get from “blank virtual machine with no idea what to do” to “kicking off my first network based installation of Windows 7”.
I was immediately overwhelmed by the coolness of all of this and got completely distracted from my original task, and spent the next hour getting 32-bit and 64-bit versions of Windows 7, Windows Server 2008 R2, Windows Vista and Windows Server 2008 loaded onto my Windows Deployment Server. I am never going to need to look for a DVD again (heck! I am never going to need to locate an .ISO file again!).
Side note – one interesting thing to note here is that you only need one 32-bit boot image and one 64-bit boot image for any number of install images. In my case I am using the Windows 7 boot images for all of the above versions of Windows. One nice benefit of doing this is that since Windows 7 has the Hyper-V integration services built in – I get integrated mouse support no matter what operating system I am installing.
Once I got this all up and running, I turned my attention back to the problem of getting Windows XP deployed with Windows Deployment Services. It turns out that with Windows XP and Windows Server 2003 the process is the same as if you want to build a Windows Vista or later deployment with your own customizations. The process looks like this:
- Install the version of Windows you want to use on a computer (or in my case – a virtual machine :-).
- Apply patches and updates, install applications and perform any customization you want to.
- Use Sysprep to prepare the operating system to be redeployed on another physical computer (or virtual machine).
- Capture the system in a .WIM file that can then be used as an installation image by Windows Deployment Services.
For this last step there are two options for for how to create the .WIM file:
- The first option is to use ImageX.exe to make the image, then copy it up to the Windows Deployment Services server and manually register the image on the server.
- You can create a capture image on the Windows Deployment Server (this is as simple as right clicking on one of your boot images and selecting to create a capture image from it). Capture images allow you to network boot a Sysprep’d system and have it be automatically captured and uploaded to your server.
I tried this all out – and it worked pretty much just as advertised.
So how does this all tie back to virtualization?
Well, to start with – there is no way I would ever have dedicated an entire physical server to being a Windows Deployment Services server in my house. Sorry – I just do not have enough systems for that (and I am the only user). But I only have a single physical server in my house. It currently runs:
- Hyper-V (of course)
- Active Directory
- DNS
- DHCP
- An FTP server
- Windows Home Server
- System Center Virtual Machine Manager 2008 R2
- Windows Deployment Services
As well as a desktop virtual machine, a Windows Deployment Services staging virtual machine, a Windows Deployment Services deployment test virtual machine and a spare installation of Windows Server 2008 R2 for trying random server software on.
But the real benefit of virtualization when using Windows Deployment Services is using a virtual machine to stage your custom installation images. Apart from the obvious hardware saving – there is a workflow benefit. If I used a physical computer for staging custom installations my workflow would look like this:
- Install Windows
- Apply patches / updates, install applications, apply customizations
- Sysprep the system
- Capture the system to the Windows Deployment Services Server
Source: http://blogs.msdn.com/virtual_pc_guy/archive/2009/08/25/geeking-out-with-windows-deployment-services.aspx
|
Hi Michel,
great article. If you like to improve the user experience of WDS you should check out OpsQuick (www.OpsQuick.com). QpsQuick simplifies WDS, enhance the functionality and transform WDS to a nice and easy to use OS image deployment tool.
Have a look at www.OpsQuick.com and test it 14-days. We currently receive great feedack from the market.
Frank