Installing Windows from USB Flash

This post is about how to prepare the USB Flash to install Windows from it.  It works fine with Windows 8.1 and Windows Server 2012. Maybe it could work with Windows 7 and Windows Server 2008 (I has not checked myself).

1) Mount Windows image. Just double-click on ISO image. Remember the letter of the drive that Windows assigned to this image. In my case it’s disk G:

2) Plug in USB flash and remember the letter of the drive. It’s H:

3) Open command prompt and do NOT close it until the end.

4) Run the following commands to create a NTFS partition on USB flash:

Command Description
diskpart starts Disk Partition tool
list disk shows a list of disks, find USB flash disk and remember its number
select disk # replace # with USB flash disk number
clean deletes everything on USB flask
create partition primary creates partition
select partition 1
active makes it active
format fs=ntfs quick quick formats with NTFS file system

5) Run the following commands to create a boot sector on USB flash:

Command Description
G: change drive, G: is a drive letter of Windows image
cd boot go to a folder
bootsect /nt60 H: create a boot sector, H: is a drive letter of USB flash

6) Copy all files from all directories, including empty subdirectories, hidden and system files from Windows image (drive G:) to USB flash (disk H:):

cd .. go to a drive root
xcopy G: H: /E /F /H

7) Close command prompt

Leave a Reply

Your email address will not be published. Required fields are marked *