How to "Burn" an ISO to a USB drive in OS X

Support this website by purchasing prints of my photographs! Check them out here.

OS X comes with a pretty handy tool for working with disks and burning disk images called Disk Utility. Unfortunately, it doesn't seem to work for burning ISO images to USB drives. Chances are, if you're reading this, you've already tried to burn an ISO image to a USB drive using the utility and were greeted with a cryptic error like this:

Unable to scan ISO file. (Invalid argument)
Unable to scan ISO file. (Invalid argument)

Basically, it means that Disk Utility has no idea what the hell it is doing.

Luckily for us, this is a BSD machine, and the terminal has some useful commands for us. Open up terminal, and run the command diskutil list. Assuming your USB drive is plugged in (hint hint), you will be greeted with a list of drives similar to this:

/dev/disk0
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *128.0 GB   disk0
   1:                        EFI                         209.7 MB   disk0s1
   2:                  Apple_HFS System                  127.2 GB   disk0s2
   3:                 Apple_Boot Recovery HD             650.0 MB   disk0s3
/dev/disk1
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *750.2 GB   disk1
   1:                        EFI                         209.7 MB   disk1s1
   2:                  Apple_HFS Media                   649.8 GB   disk1s2
   3:                 Apple_Boot Recovery HD             650.0 MB   disk1s3
   4:                  Apple_HFS Server                  99.3 GB    disk1s4
/dev/disk2
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     FDisk_partition_scheme                        *8.0 GB     disk2
   1:             Windows_FAT_32 BFPORTABLE2             8.0 GB     disk2s1

Of course your partitions won't look as cool as mine, unless you've ripped out your optical drive and shoved in a second harddrive. Anyway, one of those devices should be your USB drive. In my case, it is /dev/disk2.

At this point, you'll want to unmount the partition, although you don't want to eject the drive. I'm not really sure what that means, but it has the effect of removing the partition from being mounted in the filesystem (e.g. disk2s1 being mounted as /Volumes/BFPORTABLE2), but the disk itself is still accessible as /dev/disk2. You can open Disk Utility, right click on the Partition (but not the physical device), and click unmount (not eject).

After this, you can execute the dd command, which is used for duplicating disk drive images. You'll want to run the following command:

sudo dd if=~/Downloads/DISK-IMAGE.iso of=/dev/DRIVE-NAME bs=1m

What it all looks like in my terminal. You can see that I ran the diskutil list command to find my partition, attempted to run the dd command without sudo and it failed, then I ran it with sudo again and it failed, so I went to Disk Utility, ejected it, and ran it again and it succeeded. The process will take a while before it completes copying to your device.

Using dd to burn an ISO to a USB drive on OS X
Using dd to burn an ISO to a USB drive on OS X

Thomas Hunter II Avatar

Thomas has contributed to dozens of enterprise Node.js services and has worked for a company dedicated to securing Node.js. He has spoken at several conferences on Node.js and JavaScript and is an O'Reilly published author.