Creating bootable USB drive for UEFI computers

In today’s blog I am going to discuss how to create a multi-partition bootable USB drive for use UEFI based computers.

It is common to create bootable USB flash drives or hard drives so you can boot from them to do various tasks such as

  • Boot Windows PE (WINPE) for recovery purposes
  • Boot Windows PE (WINPE) to deploy image
  • Boot Microsoft Deployment Toolkit media deployment share

UEFI based systems such as the Surface Pro or other UEFI systems require that the boot files reside on FAT32 partition. If they are not FAT32 the system may not see the device as bootable. 

FAT32 has a 4GB individual file size limitation and 32GB maximum volume size. If any of the files are larger than 4GB you may have to configure the drive differently. Consider if you are booting Windows PE 4.0 and want to deploy a custom image using Dism.exe where the size of the image is 8GB. You would not be able to store the image on the FAT32 partition. 

To get around this you have create multiple partitions on the drive. Most flash drives report themselves as removable but to create multiple partitions the drive must report itself as Fixed. If you have access to a Windows to Go (WTG) certified drive you can use it since a requirement for WTG is that the device report as fixed. Some USB hard drives like the Western Digital Passport report themselves as fixed also. 

To verify if the drive is reporting itself as fixed or removable plug the drive in and open My Computer:

  • Drive shows up under “Hard Disk Drives”: Fixed
  • Drive shows up under “Devices with Removable Storage”: Removable

To create a USB drive with multiple partitions use the following steps

  1. Open elevated cmd prompt
  2. Type in Diskpart and hit enter
  3. Type in the following commands:

List disk
Sel disk X: (where X: is your USB drive)
Clean
Create Part Primary size=2048
Assign
Active
Format fs=fat32 quick Label=”Boot”
Create part primary
Assign
Format fs=ntfs quick Label=”Deploy”
Exit

Note: You can choose different sizes and volume labels depending on your needs

At this point you can now copy your boot files to the FAT32 partition and your other files to the NTFS partition. 

In the earlier example you would copy the contents of your custom Windows PE (WINPE) 4.0 files in C:\winpe_amd64\media to the FAT32 partition and your custom install.wim to the NTFS partition

Hope this helps with your deployments

Scott McArthur
Senior Support Escalation Engineer
Microsoft Commercial Services & Support