Create a WinPE ISO with VirtIO Drivers included for Recovery or Restore Processes



  • In situations where it is necessary to boot a VM to a rescue environment, and a Windows recovery environment is preferred, Microsoft has made it extremely easy to create a CD image that can be uploaded to an HC3 cluster and used as a boot drive for a VM.

    These steps were used on a Windows 10 host, and Microsoft will likely have much more comprehensive information and would be better suited for assistance in case of issues or disparities...

    It is assumed that these steps will be run on an HC3 cluster, where the Scale Tools CD is mounted and accessible to a Windows VM.

    First, download and install the Windows Assessment Deployment Kit as listed on Microsoft's WinPE walkthrough.

    According to that walkthrough, the Deployment Tools and Preinstallation Environment components are required for installation.

    Once complete, start the "Deployment and Imaging Tools Environment" application that was installed with elevated privileges (Start -> type 'deployment', right click and select "Run as administrator") and use the following commands:

    1. copype amd64 C:\WinPE_amd64
    2. dism /mount-image /imagefile:"c:\winpe_amd64\media\sources\boot.wim" /index:1 /mountdir:"c:\winpe_amd64\mount"
    3. dism /add-driver /image:"c:\winpe_amd64\mount" /driver:"e:\drivers\net\w10\netkvm.inf"
    4. dism /add-driver /image:"c:\winpe_amd64\mount" /driver:"e:\drivers\serial\w10\vioser.inf"
    5. dism /add-driver /image:"c:\winpe_amd64\mount" /driver:"e:\drivers\stor\w10\viostor.inf"
    6. dism /unmount-image /mountdir:"c:\winpe_amd64\mount" /commit
    7. MakeWinPEMedia /ISO C:\WinPE_amd64 C:\WinPE_amd64\VirtIO-WinPE_amd64.iso

    The machine architecture, filenames and paths above are all dependent upon the environment and configuration choices.

    Lastly, upload the created ISO (C:\WinPE_amd64\VirtIO-WinPE_amd64.iso) to the HC3 cluster, insert the ISO into a VM's empty CDROM, and start the VM.

    With the VM booted to the PE ISO, a SMB share can be mounted and files copied as needed, or other recovery operations completed. For example, to mount a SMB share from a remote host:

    net use * \fileserver\share * /user:[email protected]
    

    Further customization and capabilities can be applied and configured prior to the above step 7, as needed, but extend beyond the initial needs of this post.

    Information for the above was gathered from the following Microsoft pages:

    WinPE: Create a Boot CD, DVD, ISO, or VHD
    WinPE: Add drivers



Looks like your connection to MangoLassi was lost, please wait while we try to reconnect.