How to Add Device Drivers to an Offline Windows PE Image

Applies To: Windows 8, Windows Server 2008 R2, Windows Server 2012

You can add a device driver (.inf file) to an offline Windows® Preinstallation Environment (Windows PE) image by using the Deployment Image Servicing and Management (DISM) tool. If driver installation requires restarting the computer, do not install the driver online, because Windows PE typically runs from RAM disk and cannot provide persistent storage for the driver. Instead, add the driver to the offline Windows PE image. During online installation of a driver in Windows PE, if the driver .inf file requires that the computer restart, Windows PE ignores the request. If the driver .sys file requires that the computer restart, you must install the driver to the offline Windows PE image.

To add a driver

  1. Mount the base image to a local Windows PE directory. For example:

    Dism /mount-image /imagefile:C:\winpe_amd64\winpe.wim /index:
        <image#>
       /mountdir:C:\winpe_amd64\mount
    

    where <image#> is the number of the selected image on the .wim file.

  2. Add the .inf file to the base image by using the Dism command together with the /Add-Driver option. For example:

    Dism /image:
        <path>
       /add-driver /driver:C:\winpe_amd64\mount\Windows\driver.inf
    

    where <path> is the path to the Windows PE image.

    To learn more about how to add drivers offline by using the /Add-Driver option, see Driver Servicing Command-Line Options.

  3. Repeat steps 1 and 2 for each additional device driver.

  4. After you have modified the image, unmount the image, and then commit changes to the image. For example:

    Dism /unmount-image /mountdir:C:\winpe_amd64\mount /commit
    

    After you unmount the image, you can burn the image to the designated media. For more information, see Windows PE Walkthroughs.

See Also

Tasks

How to Add and Remove Drivers Offline
How to Configure Windows Firewall with Advanced Security Settings in Windows PE
How to View Current Optional Components in Windows PE
How to Add a Language Pack to Windows PE
How to Add an Optional Component to Windows PE
How to Add an Update to Windows PE
How to Add an Application to Windows PE
How to Include a Custom Script in Windows PE
How to Add Device Drivers to an Online Windows PE Image

Reference

Image Management Command-Line Options

Concepts

Device Drivers and Deployment Overview
How to Add a Driver Online in Audit Mode