Windows Developer Preview – Create a WinPE 4.0 Boot ISO

You must be a Microsoft Partner or have an MSDN subscription in order to download ADK (formerly called WAIK).

Info here:

Extract/install ADK ( on a machine…

(The setup file is called “adksetup.exe” at the time of this writing after extracting the ZIP as you do not need to run each MSI individually 🙂 .)

Navigate to:

C:\Program Files\Windows Kits\8.0\Assessment and Deployment Kit\Windows Preinstallation Environment\x86\Media

Copy this folder to your ISO builder machine with ADK installed:


Now, copy C:\Program Files\Windows Kits\8.0\Assessment and Deployment Kit\Windows Preinstallation Environment\x86\en-us\winpe.wim into:

C:\Temp\WinPE\Media\Sources (make this new folder)

Rename the “winpe.wim” to “boot.wim
Copy both “” and “oscdmg.exe” from:

C:\Program Files\Windows Kits\8.0\Assessment and Deployment Kit\Deployment Tools\x86\Oscdimg



Now, with all the base tools in place, it is time to create the ISO:

Open Deployment Tools Command Prompt (Elevated).

Change your directory to:


Run the following command:

oscdimg.exe -b"" -n Media ISOFILENAME.iso

OK, that’s a brand new WinPE 4.0 “vanilla” disk for you.



What about some additional drivers or applications?

We are going to have to edit that default WinPE.wim (renamed above to boot.wim) with new stuff!

How-to add some optional components…

They all live in the following directory:

C:\Program Files\Windows Kits\8.0\Assessment and Deployment Kit\Windows Preinstallation Environment\x86\WinPE_OCs

Copy them to:


Create a mount point for the base WIM.
This is a fancy sentence for make a new folder from the deployment tools command line:


From C:\Temp\WinPE, run:

imagex.exe /mountrw Media\Sources\boot.wim 1 c:\MOUNT

Add your new optional components:

dism /image:c:\MOUNT /add-package /PackagePath:"C:\Temp\WinPE\WinPE_OCs\"

Add the associated language portion of the package (otherwise the package you just added won’t work):

dism /image:c:\mount /add-package /PackagePath:"C:\Temp\WinPE\WinPE_OCs\en-us\"

NOTE: If you want Powershell support in your WinPE 4.0 environment (,, it also requires .NET4 (, to process. Make sure to add all four listed here.

Let’s add some drivers:

dism /image:c:\MOUNT /add-driver /driver:"C:\Path\To\Driver\NIC.inf"

If you are lazy and have stand-alone executables that can run, you can also just drop them right into the mounted ISO directory:

Make a new folder to hold them:

Copy tools you can run via command line here (Sysinternals’ Process Explorer, etc.)

Commit the changes (or lose all your hard work!):

imagex.exe /unmount /commit C:\MOUNT

Note: Make sure to close any Explorer.exe processes that have your working directories open, or the unmount process “sticks” and doesn’t unmount correctly.

Regenerate your ISO with the same command from above:

oscdimg.exe -b"" -n Media ISOFILENAMEv2.iso


Edit the WinPE Registry for your own customization:

Mount the hive from the deployment tools command prompt:

reg load HKLM\Temp c:\mount\Windows\System32\config\DEFAULT

Open REGEDIT on your builder workstation. Edit to your will manually or import a previously written .REG file

Example (if you opened MyCustomSettings.reg in Notepad I have saved on my desktop, it would read):

Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\Temp\Software\Sysinternals\Process Explorer]

Now you have green display text instead of the standard white and the EULA has been accepted for Sysinternals Process Explorer.
IMPORTANT: UNLOAD THE REGISTRY HIVE WHEN COMPLETED! (File > Unload Hive) if you don’t want to have that hive loaded permanently on your builder machine. Regenerate your ISO file using oscdimg.exe above.


Edit: Updated file paths. Assuming you are building an x86 WinPE environment on x86 OS.

16 responses to “Windows Developer Preview – Create a WinPE 4.0 Boot ISO

  1. First of all, thanks for the guide.

    I’ve found a few errors in your guide:
    1. In the sentence “Now, copy C:\Program Files (x86)\Windows Kits\8.0\Assessment and Deployment Kit\Windows Preinstallation Environment\x86\winpe.wim into:”

    …You forgot to add “en-us” to the end of the path.

    2. You should really mention closing all explorer windows PRIOR to un-mounting the image. Well, you do mention it, but you mentioned it only after the command. Write the warning before the command.

    All in all, a really thorough and enlighting guide.

  2. I keep getting the following errors when running the dism commands:
    Processing 1 of 1 – Adding package WinPE-Scripting-Package~31bf3856ad364e35~x86~
    [===========================60.0%== ]
    An error occurred – WinPE-Scripting-Package Error: 0x80070005

    Error: 5

    Access is denied.

    The DISM log file can be found at C:\WINDOWS\Logs\DISM\dism.log

  3. Cory,
    Excellent guide. At this time (06/28/2012) the ADK for the Windows 8 Release Preview is available at the link in your article. It can be accessed by the general public and uses build 8400 for the WinPe image. I followed your guide to create a “vanilla” WinPe image file, and then used Acronis True Image Home 2012 plus pack WinPE Builder to add Acronis True Image Home 2012 with Plus Pack to my image. I created the ISO following your instructions, and it worked like a charm. The 8400 build of WinPE 4.0 has more driver support built-in then Windows 7 based WinPE 3.0, and works great.
    Thanks for taking your time to share your knowledge.
    Kudos to Eric as well for catching the “path” ommission.

      • I had both the Acronis 2012 main program and the plus pack installed on my system. I used the Plus Pack WinPE builder and pointed to the winpe.wim file on my desktop that I had copied from C:\Program Files\Windows Kits\8.0\Assessment and Deployment Kit\Windows Preinstallation Environment\x86\en-us\winpe.wim. I had the Plus Pack WinPE builder place the resulting new .wim file on my desktop. I then renamed the .wim, that the Plus Pack WinPE builder modified, to boot.wim, and copied it to the C:\Temp\WinPE\Media\Sources folder, and continued the steps to build the ISO from you original post. Works like a charm. Also injected some Win7 drivers for chipsets and storage controllers that are not present in the 8400 build to support some systems I have used this boot disk on.

    • Hi there. What are you trying to do with WinPE 4.0 and PXE services?
      I usually just use MDT for my WIM (PXE) images, but also have used DaRT 7.0 as a PXE image.

      • Sorry; I thought MDT was part of Windows Deployment Services. Right now we have our DHCP server pointing to the boot file named “pxelinux.” We have several entries for booting into network tools used across our campus. Our TFTP server and DHCP are all running on a Linux box. Before with WinPE 3.0 I copied everything under the ISO directory after running the “copyepe.cmd” script.

        I’m not sure how this is done with WinPE 4.0 since the files are somewhat different. Here’s the tutorial that I followed a year ago to do this: (this is WinPE 2.0 but the setup was similar).

        I’m looking into MDT right now, thanks for the help.

      • I was able to resolve the issue on my own after looking back on how I did this for WinPE 3.0. I forgot the PXE files are located inside the wim itself (been a while since i’ve played with this). Thanks for the help.

  4. Hi there.
    whene I boot from WinPE 4.0 and tray this command
    f:\imagex /comress maximum /check /flags “ultimate” /capture C: D:\install.wim “WIN7ULTI”

    I have this error:
    f:\imagex is not recognized as an internal or external command ,operable program or batch file

    • If you made a Tools folder, you will have to change directory (“CD Tools” from the Command Prompt window) into that folder to utilize what you copied in there.
      The tools also have to be compatible with PE mode, or they will fail to run.

  5. @Qwertyess
    If you copy the imagex files to your winpe c:\windows\system32 it will work from any location when in PE.

Leave a Reply to Cory Calahan Cancel reply

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

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

Google photo

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

Twitter picture

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

Facebook photo

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

Connecting to %s