Sysprep is a Windows System Preparation Tool that prepares an installation of a running Windows for duplication, auditing and customer delivery. It enables you to capture a customized Windows image that you can reuse throughout an organization. A typical Sysprep process consists of the following steps:
- Install a Windows on a reference computer with all latest device drivers and updates.
- Install all other necessary applications and make all the customized changes.
- Once all done, run the command
sysprep /oobe /generalize.
/oobeoption instructs the Windows system to run Windows Welcome the next time the computer boots, giving an Out-of-Box Experience.
/generalizeoption tells Sysprep to remove system-specific data from the Windows installations.
- After the reference computer shuts down, you can boot to Windows PE on the same computer, and capture the Windows installation with ImageX. We actually have a post that you can refer to for details.
The Sysprep command is located in the following path:
You can either double-click the sysprep.exe executable file to launch it directly with a GUI like below:
or use it as a command line with a number of switches available.
One of the switches, /mode, is new since Windows 8 that generalizes an image that can be deployed in a virtualized environment. Let’s say you have prepared a reference computer as a VM in Hyper-V, to Sysprep it, run the following command inside the VM to .
Sysprep /generalize /oobe /mode:vm
The only additional switches that apply to VM mode are /reboot, /shutdown, and /quit.
Note #1: It works the best when deploying the VHD to a different VM with a matching hardware profile.
Note #2: While it’s stated that it works for VHD in Hyper-V environment, it should also work with VMware as well.
Note #3: You can’t deploy the
/mode:vm prepared image to a physical machine.
Latest posts by Kent Chen (see all)
- The Page File (PageFile.sys) Guide for Windows 7, 8.1 and 10 - February 22, 2017
- How To Enable and Use Fetch Files Feature in OneDrive to Access All Your Files Remotely - February 21, 2017
- Speed Up Email Search for Outlook and Gmail with Email Insight App - February 20, 2017
Last updated: 07/29/2016