Create a WinPE Bootable ISO image / USB drive

C

We need a WinPE image as a per-requisite for us to capture the operating system. WinPE is a pre installation environment which allows us to do many things.

If you haven’t installed WinPE on your system you can download and install WinPE by downloading “Windows Assessment and Deployment tool kit” (ADK). This software is essential for us to create a WinPE bootable ISO image. Alternatively you can download the WinPE ISO image from sources on internet.

Let’s see how we can create a bootable WinPE ISO image.

After installing ADK on your machine, run the ADK tool as administrator and run the command

copype amd64 c:WinPE

The above command creates a directory containing a standard set of Windows Pre installation Environment (Windows PE) files. We use these files to customize images and create bootable media.

CopyPE

We can verify the directory the above command created at “C:WinPE”. This command creates a “WinPE” directory with 3 sub directories with names “mount”, “media” and “fwfiles”. “media” folder contains all the necessary files for creating WinPE ISO image.

WinPE Folder Structure

Since the goal of this exercise is to capture an operating system. We need not add any additional packages or features that WinPE allows us to do.

So let’s create a simple WinPE image. This can be done using the command

makewinpemedia /iso "C:WinPE" "C:WinPEWinPE64.iso"

makewinpemedia

Now you can use the ISO image at “C:WinPEWinPE64.iso” to burn onto a CD/DVD or alternatively can copy the files of this ISO image into a bootable USB partition.

Creating a Bootable USB drive

Now let us create a bootable USB drive for the WinPE ISO image that we have just created. Open up the command prompt by typing “cmd” in runbox.

Plug in the USB device and open up the diskpart by typing the following command

diskpart

It opens up the Microsoft diskpart utility using which we can manage the volumes attached to our machine.

List all the volumes connected to the device using the following command

list volume

Now select the volume of the USB in which you want to create a bootable ISO image using the command

select volume 5

*Please be noted that the volume number will differ in your system.

As we have selected the volume, let us clean the volume for removing any previous MBR or GPT partition data using the command

clean

Create Bootable USB

Now lets create a primary partition in the volume using the command

create partition primary

unlike previous volumes, partitions start numbered from 1. To verify lets list partition using list partition and select the only partition that we have created as follows

list partition

 

select partition 1

Now let us make the partition active so that BIOS or EFI can recognize our partition as a valid system partition and quick format the drive using NTFS file format.

active
format fs=NTFS quick

Lets assign a letter to the drive so we can copy our WinPE files onto the drive.

assign

USB drive Boot

Once you have copied the WinPE iso files onto the USB drive. Pendrive is ready to boot.

Following is the summary of list of commands we have used.

list volume
select volume # //where # is the volume number of USB drive
clean
create partition primary
select partition 1
active
format fs=NTFS quick
assign

Please let me know your comments/feedback in comments section.

About the author

pavankumar.p1990

Add comment

By pavankumar.p1990