Create WIMBoot Images

Windows image file boot (WIMBoot) helps you save hard drive space by booting to a WIM file rather than a set of uncompressed Windows files. For more info about WIMBoot images, see Windows Image File Boot (WIMBoot) Overview.

To save room on the images, separate the Windows Recovery Environment (Windows RE) image from the main Windows image. Otherwise, this image will take up 200 MB or more of extra drive space in your image and will otherwise never be used.

The Windows RE image is stored inside the main Windows image at \Windows\System32\Recovery\winre.wim as a hidden file.

This page focuses on a method to create WIMBoot images that use a minimum of drive space. It also discusses other methods to create WIMBoot images to reduce the total number of Windows images that you manage.

Dn898520.wedge(en-us,VS.85).gifPrerequisites

  1. Install Windows 8.1 Update to your Windows 8.1 and Windows RE images. For more info, see Install the Windows 8.1 Update for OEMs.

  2. On your technician PC, install the Windows 8.1 Update version of the Windows Assessment and Deployment Kit (Windows ADK).

  3. Create a Windows PE 5.1 bootable drive by adding the Windows 8.1 Update packages to Windows PE 5.0, and then cleaning up the image. For more info, see Update WinPE 5.0 to WinPE 5.1.

Dn898520.wedge(en-us,VS.85).gifCreate a temporary copy of the install.wim image

  • Copy the install.wim to a new temporary file. You'll use this copy of the file to create your WIMBoot image.

    Copy C:\Images\install_updated.wim C:\Images\install_temp.wim
    

Dn898520.wedge(en-us,VS.85).gifSeparate the Windows RE image from the main Windows image

  1. Create a mount directory for your install.wim files and mount the image.

    md C:\mount\Windows
    
    Dism /Mount-Image /ImageFile:"C:\Images\install_temp.wim" /Index:1 /MountDir:C:\mount\Windows
    
  2. Unhide the Windows RE image (winre.wim).

    attrib –s -h C:\mount\Windows\Windows\System32\Recovery\winre.wim
    
  3. Move winre.wim out of the image.

    move C:\mount\Windows\Windows\System32\Recovery\winre.wim C:\images\winre.wim
    

Dn898520.wedge(en-us,VS.85).gifOptimize the Windows image for WIMBoot (optional)

  • Optimize the image for WIMBoot to gain free drive space in the final image.

    • Note, optimizing the image removes features for on-demand installation that might be needed for enterprise PC deployments. For more info, see Enable or Disable Windows Features Using DISM.

      Dism /Optimize-Image /Image:C:\mount\Windows /WIMBoot
      
    • If you don’t optimize the image, you’ll be able to use your final WIMBoot image for both traditional (flat-boot) and WIMBoot deployments. This can help you manage fewer images in the deployment process.

Dn898520.wedge(en-us,VS.85).gifUnmount the image

  • Unmount the image and commit the changes.

    Dism /Unmount-Image /MountDir:C:\mount\Windows /Commit
    

Dn898520.wedge(en-us,VS.85).gifBoot the image to apply the updates and to clean up the image

  1. On your reference PC, boot to Windows PE 5.1, apply your Windows image, and then boot the PC again. For more info, see Samples: Applying Windows, System, and Recovery Partitions by using a Deployment Script.

  2. Press CTRL+SHIFT+F3 at OOBE to enter audit mode.

  3. Clean up the Windows image to gain additional free drive space in the final image. Use /StartComponentCleanup to clean up the superseded components and reduce the size of the component store. If you've already used the /ResetBase option when creating your base Windows 8.1 Update image, you don't need to run it again. To see the file size reduction, you'll need to either recapture or export the image.

    Dism /Cleanup-Image /Online /StartComponentCleanup
    
  4. Use Sysprep to generalize and shut down the PC.

    C:\Windows\System32\Sysprep\sysprep /generalize /shutdown /oobe
    
  5. Boot the PC to Windows PE 5.1. If the PC starts to reboot to Windows, you'll need to let it finish booting and then use Sysprep to generalize and shut down the PC again.

  6. Recommended: Create a temporary scratch directory, for example, C:\Recycler\Scratch. Choose a location on a physical drive to avoid issues related to capturing files with long file names in the default Windows PE virtual scratch space. Choose a space that’s in the DISM Exclusion list to prevent capturing the DISM logs in your image. For more info, see DISM Configuration List and WimScript.ini Files.

    md C:\Recycler\Scratch
    
  7. Recapture the Windows image. This captures the applied updates and removes any files that were marked as superseded during DISM /Cleanup-Image. Use the /WIMBoot option to save the image as a WIMBoot image. Save the file to a location on a USB drive or your network (example: N:\Images), and give the image a name (example: Enterprise_x64 with 8.1 Updates).

    DISM /Capture-Image /WIMBoot /ImageFile:"N:\Images\install_wimboot.wim" /CaptureDir:C: /Name:"WIMBoot Enterprise_x64 with 8.1 Updates" /ScratchDir:C:\Recycler\Scratch
    

Method 2: Add WIMBoot support to a standard image

Dn898520.wedge(en-us,VS.85).gif

  • To quickly add WIMBoot support to a standard (flat-boot) image to a WIMBoot image, you can either capture or export the image. The final image size will be larger than the original WIM file, because WIMBoot uses a different compression algorithm. You can use the instructions from Method 1 to optimize the image size.

    You’ll also need a separate, updated Windows RE (winre.wim) file. For more info, see Install the Windows 8.1 Update for OEMs.

    Example:

    Dism /Export-Image /WIMBoot /SourceImageFile:C:\Images\install.wim /SourceIndex:1 /DestinationImageFile:C:\Images\install_wimboot.wim
    

Optional: Confirm the image is configured for WIMBoot:

Dn898520.wedge(en-us,VS.85).gif****

  • Use DISM to check to make sure the image is configured correctly:

    Dism /Get-ImageInfo /imagefile:C:\Images\install.wim /Index:1
    

    In the output, you should see the following line:

    WIM Bootable : Yes
    

Dn898520.wedge(en-us,VS.85).gifAdditional notes

  • Don’t append images into an existing WIM file, because WIMBoot only supports using the first Windows image in the file (index value of 1).

Dn898520.wedge(en-us,VS.85).gifNext steps: Deploy the WIMBoot images

Windows Image File Boot (WIMBoot) Overview

Install the Windows 8.1 Update for OEMs

Update WinPE 5.0 to WinPE 5.1

Take Inventory of an Image or Component Using DISM