I need to create a Windows installation USB drive from an ISO file. I used UNetbootin which seems to be the only tool that can write non-Linux images.

The USB disk boots (sort of), but it gets stuck at the very first stage. A UNetbootin splash screen appears that keeps counting down from 10 to 0, and then restarts.

The screen looks like this:

enter image description here

Is there a way to make Windows boot from a USB image created on Linux?

  • As far as I know it only works on an NTFS partition, so re-format your thumb drive. This brings another problem, because version 494 of unetbootin is the latest that could write to ntfs partitions, so use that one instead of the current. – Cumulus007 Aug 25 '12 at 21:29

Method 1

Using gparted format the drive FAT16, set the boot flag.

Using Archive Manager extract the iso to the drive.

(or just copy the DVD to the drive).

That's it.

works for me

Method 2

To create your bootable installer disc, select an ISO image or CD/DVD disc, and click Install enter image description here

This will create your Windows Vista/7 installer USB. It is worth mentioning here that the tool might also work with Windows 8; however, it has not been tested. Having said that, the developer has mentioned that the supported images include, “Windows Vista, Seven+.” You can install WinUSB either from the Deb package given at the developer’s website (for Oneiric, Natty, Maverick and Lucid), or from the PPA given below.

sudo add-apt-repository ppa:colingille/freshlight
sudo apt-get update
sudo apt-get install winusb

Since WinUSB also works from the command line, you can create a Windows 7 or Windows Vista USB installer by following the command line format given below

sudo winusb --format <iso path> <device>

Once the USB is formatted using the above method, install a Windows partition and edit the Master Boot Record:

sudo winusb --install <iso path> <partition>
  • 1
    You mean you do not even need to use unetbootin or similar tools? – Salim Fadhley Mar 28 '12 at 23:35
  • That will copy the ISO content to USB, but will it make the USB bootable? – mikewhatever Mar 28 '12 at 23:39
  • 2
    Yes that will make USB bootable only u have to format the drive into FAT16 using gparted tool – twister_void Mar 28 '12 at 23:42
  • 1
    This is usless to me unless it boots? I do not understand how Gaurav_Java's technique could make the disk bootable. Setting the boot flag only marks a partition as bootable but does not tell the computer what to boot. How on earth could this work? – Salim Fadhley Mar 28 '12 at 23:46
  • 3
    @SalimFadhley, remember that method 1 also talks about using the Archive Manager to extract the Win7 ISO on the pendrive, so it does work, but as far as I know, doesn't it should also work with FAT32? Thumbs up for the WinUSB method. – crackout12 Mar 29 '12 at 0:04

Its a simple process.

For BIOS: MBR partition scheme

  1. Format the USB to FAT32 and mark it with the 'boot' flag. (NTFS works too, but for this tutorial I'm using FAT32 because you can make it UEFI bootable this way.)
  2. Mount the USB somewhere, for example /media/<user>/<disc_label>
  3. Install grub to the USB using:

    grub-install --force --no-floppy --boot-directory=/media/<user>/<disc_label>/boot /dev/sdX

    (Install to the disk; not partition!)

  4. Extract the contents of the iso onto the root of the USB stick; I personally use 7z for this:

    7z x /path/to/win.iso

    (Note that the Win7 iso has a boot dir; you will need to 'overlap' the boot dir created with grub with the contents of the iso. )

    You should end up with something like this

    ├── autorun.inf
    ├── boot
    │   └── grub
    ├── bootmgr
    ├── efi
    ├── setup.exe
    ├── sources
    ├── support
    └── upgrade
  5. Edit/create boot/grub/grub.cfg so it contains the following menuentry:

    menuentry 'Windows 7 AIO Installer' --class windows --class os {
      set root=(hd0,1)
      insmod part_msdos
      insmod fat
      insmod ntldr
      ntldr /bootmgr
  6. When you reach the grub prompt (grub>) type boot and press Enter

  7. Enjoy your bootable stick.

    It may be a bit of a runaround, but this lets you add addtional resources as needed via edits to the grub.cfg file. I personally have a Windows 7 All In one (9 editions of win7) installer, Mini Windows XP (from hirens), DOS 6.22, memtest, and gparted live on one usb stick this way.

For UEFI: GPT partition scheme *

  1. Copy efi/microsoft/boot one level upward:

    cp -r efi/microsoft/boot efi/boot/

    (The path may be all uppercase, lowercase, or a mix, due to the case-insensitive nature of the FAT32 filesystem and differing mount options. Adjust commands to fit your situation.)

  2. Extract 1/Windows/Boot/EFI/bootmgfw.efi from sources/install.wim

    7z e sources/install.wim 1/Windows/Boot/EFI/bootmgfw.efi
  3. Place this file as efi/boot/bootx64.efi

    mv bootmgfw.efi efi/boot/bootx64.efi
  4. Enjoy your UEFI-bootable windows 7 USB!

  • Um... Unless I'm mistaken, doing the above will not result in a grub> prompt if done correctly. However, it has been quite some time since I've had to use this technique. – hanetzer May 25 '16 at 17:07
  • As a gentoo user, can confirm this works (Hey Hanetzer!) – djsmiley2kStaysInside Dec 19 '17 at 21:34

Not the answer you're looking for? Browse other questions tagged or ask your own question.