I have a Windows 7 iso file which I wish to burn into a usb to make it bootable. I tried with the Disks utility "Restore Disk Image" and it copied the iso files into the drive but it didn't make it bootable. I tried using Etcher but when I selected the Windows iso file I got a message saying that Windows iso files required a special burning process to make them bootable and that I had to use a tool such as Rufus which isn't available for Linux and Wine couldn't run it properly.
1 Answer
I always use dd
for this, and it has never failed. Yes, it works for Windows ISO's too.
Here's how I normally go about it (as root -or use sudo
):
dd if=/path/to/your/iso of=/dev/sdX bs=4M;
The X
in sdX
is the where your USB device is connected. Be very careful tho choose the right one! Otherwise you might overwrite the wrong disk/partition.
One way to find out the right device is to issue ls -l /dev/disk/by-id/
.
Below is an example, where you see that the USB device is located on /dev/sdb
:
ls -l /dev/disk/by-id/ totalt 0 lrwxrwxrwx 1 root root 9 11 okt 12.36 ata-MATSHITADVD-RAM_UJ-842S -> ../../sr0 lrwxrwxrwx 1 root root 9 11 okt 12.37 ata-TOSHIBA_MK8009GAH_Z8A1W9THW -> ../../sda lrwxrwxrwx 1 root root 10 11 okt 12.37 ata-TOSHIBA_MK8009GAH_Z8A1W9THW-part1 -> ../../sda1 lrwxrwxrwx 1 root root 10 11 okt 12.37 ata-TOSHIBA_MK8009GAH_Z8A1W9THW-part2 -> ../../sda2 lrwxrwxrwx 1 root root 10 11 okt 12.37 ata-TOSHIBA_MK8009GAH_Z8A1W9THW-part3 -> ../../sda3 lrwxrwxrwx 1 root root 9 11 okt 12.41 usb-SanDisk_U3_Cruzer_Micro_3512330F5580ED45-0:0 -> ../../sdb lrwxrwxrwx 1 root root 10 11 okt 12.41 usb-SanDisk_U3_Cruzer_Micro_3512330F5580ED45-0:0-part1 -> ../../sdb1 lrwxrwxrwx 1 root root 9 11 okt 12.41 usb-SanDisk_U3_Cruzer_Micro_3512330F5580ED45-0:1 -> ../../sr1
-
1You can also use the /dev/disk/by-id/ names directly with dd. So just do
dd if=/path/to/your/iso of=/dev/disk/by-id/usb-SanDisk_U3_Cruzer_Micro_3512330F5580ED45-0:0 bs=4M
– masgoCommented Mar 27, 2017 at 13:36 -
@masgo Thanks buddy, you taught me something new!– anonCommented Mar 27, 2017 at 13:38
-
the
/disk/by-id/
is really great. Also for things like software RAID systems, fstab, etc. You always get exactly the drive you expect. If the drive is not there you will get a decent error message. While using /dev/sdX causes a lot of trouble if you replace the drive, or if you re-wire your drives. - The only real drawback is: if you clone your drive and replace it with the clone it will not work until you changed your config - but I like this sort of explicit handling.– masgoCommented Mar 27, 2017 at 13:42