97

what's the best way to get an ISO "burned" to a USB stick on a Mac? Restoring using Disk Utility does not work.

The ISO is ubuntu mini.iso. It is the minimalist install ISO for installing ubuntu. It needs to be bootable on a PC. I am trying to install ubuntu on a PC that has no CD-ROM. The only other computer I have around is a macbook.

2
  • 1
    Can you please be a bit more descriptive in what you are trying to accomplish. I think I have an idea of what the problem is but your question is vague
    – ricbax
    Oct 31, 2009 at 19:18
  • I'm trying to "burn" a bootable ISO of the ubuntu mini.iso onto a USB stick for use on a PC. The PC in question does not have a CD-ROM. I don't have any other linux or win machines around. Oct 31, 2009 at 19:28

9 Answers 9

126

Directly from the How to install Ubuntu on MacBook using USB Stick page (my formatting):

  1. Download the desired file
  2. Open the Terminal (in /Applications/Utilities/ or query Terminal in Spotlight)
  3. Convert the .iso file to .img using the convert option of hdiutil (e.g., hdiutil convert -format UDRW -o ~/path/to/target.img ~/path/to/ubuntu.iso)
  4. Note: OS X tends to put the .dmg ending on the output file automatically. Remove the .dmg extension as necessary, mv ~/path/to/target.img{.dmg,}
  5. Run diskutil list to get the current list of devices
  6. Insert your flash media
  7. Run diskutil list again and determine the device node assigned to your flash media (e.g. /dev/disk2)
  8. Run diskutil unmountDisk /dev/diskN (replace N with the disk number from the last command; in the previous example, N would be 2)
  9. Execute sudo dd if=/path/to/downloaded.img of=/dev/rdiskN bs=1m (replace /path/to/downloaded.img with the path where the image file is located; for example, ./ubuntu.img or ./ubuntu.dmg).
  10. Using /dev/rdisk instead of /dev/disk may be faster.
    • If you see the error dd: Invalid number '1m', you are using GNU dd. Use the same command but replace bs=1m with bs=1M.
    • If you see the error dd: /dev/diskN: Resource busy, make sure the disk is not in use. Start Disk Utility.app and unmount (don't eject) the drive.
  11. Run diskutil eject /dev/diskN and remove your flash media when the command completes
  12. Restart your Mac and hold down Alt while the Mac is restarting to choose the USB stick

Note: On newer Macs you might have to install an EFI boot manager to boot from USB.

See also: Download Ubuntu Desktop.

7
  • 13
    Maybe people were not "blindly" up voting this. Maybe ... like me, they googled how to burn an ISO to a USB drive on MacOS, ya know THE TITLE OF THIS QUESTION ... found this ... and it worked. Geez. +1 Jan 12, 2012 at 7:36
  • 8
    I'm not sure what all the uproar is about. The answer is 100% on topic, works perfectly, and the resulting drive isn't any more platform-specific than the ISO you burned to it. I've used these instructions to burn OS installer ISO's (Ubuntu, WinXP, etc.) to a flash drive and the result worked perfectly on a PC.
    – spaaarky21
    Feb 15, 2012 at 3:08
  • 2
    Nope, I just failed to boot on a PC with the USB key created this method on my MacMini. The problem seems to be it lacks the ability to be booted on by the BIOS.
    – Nicocube
    Apr 16, 2012 at 16:11
  • 4
    If you want to see progress, ensure you have pv installed, and run pv /path/to/downloaded.img | sudo dd of=/dev/rdiskN bs=1m instead of sudo dd if=/path/to/downloaded.img of=/dev/rdiskN bs=1m.
    – jvatic
    May 19, 2014 at 18:46
  • This failed for me as well, I needed to use @neesh answer to get the USB to be bootable on a PC. The conversion from iso to img must not preserve any boot support. Also wondering if simply skipping the conversion would work too--but as rab points out below, might not work with UEFI.
    – notbrain
    Dec 30, 2017 at 17:40
18

I had a very similar problem that none of these answered.

It's worth checking out UNetbootin. It will create a bootable USB disk on a Mac for a PC.

3
  • Once done, unetbootin said that I had to boot it on a PC and that it won't boot on a Mac. Trying the command line suggestion now.
    – balupton
    Mar 27, 2013 at 14:17
  • For a Chrome Pixel, the UNetbootin method worked, command line didn't.
    – mjibson
    May 24, 2013 at 21:49
  • It is to my understanding that UNetbootin doesn't work on Mountain Lion.
    – 2rs2ts
    May 30, 2013 at 3:09
13

There is no need to convert the ISO to an IMG. I wasn't willing to convert an image first. This has easier steps, outlined below.

Start by listing the current disks and volumes:

diskutil list

Now unmount the current volume for the disk you are about to overwrite. (X = Drive number, in my case was 1):

diskutil unmountDisk /dev/diskX

Now dd the iso directly to the usb (again replace X with drive number of your USB drive):

sudo dd if=/pathto/mini.iso of=/dev/diskX bs=1m

Done!

1
  • This used to work, but I think the newer UEFI boot software doesn't understand the resulting file (2017). BIOS systems will work though. A way that works and is still easy is to use OS X's Boot Camp Assistant. Point it to an ISO and USB key, and it creates a UEFI bootable stick.
    – Rab
    Jul 5, 2017 at 8:32
7

This is a very old question but still benefits from updated answers.

Etcher is now the solution recommended by Ubuntu to burn iso images to a USB drive.

Etcher makes the process almost painless if you are not comfortable with the command line. It's only 3 steps and worked on the first try for me.

3
4

The way to do this using DiskUtility is to first format the drive using Diskutility and then copy over the files from the mounted iso to the newly formated drive using cp -R. Ex: cp -R /Volumes/mounted_iso/* /Volumes/formated_drive/

When formatting be sure to pick the ntfs file system and make the disk bootable by picking the correct option from the Options menu in the erase tab.

1
  • This was what worked for me to burn a Win10 bootable USB from macOS Sierra. The conversion from iso to img must strip out the master boot record on the disk. By reformatting with MBR and copying files, worked great.
    – notbrain
    Dec 30, 2017 at 17:38
2
  1. Ensure the USB Key is properly formatted (Master Boot Record, FAT32 - if necessary NTFS using NTFS-3G)
  2. You can try using the Restore feature in Disk Utility by clicking on the USB key's volume, then clicking on the Restore tab and choosing the ISO to restore onto it.
  3. If step 2 fails, you can do this manually by running ditto or cp -r; eg. ditto /Volumes/NAME_OF_MOUNTED_ISO /Volumes/NAME_OF_USB_KEY or cp -r /Volumes/NAME_OF_MOUNTED_ISO /Volumes/NAME_OF_USB_KEY to manually copy all the files (including hidden ones)
2
  • @Chealion thanks for your response. I was actually trying to get an Ubuntu ISO onto my USB, so I eventually just used the Ubuntu install disc to run it in Live Mode on my Macbook. From there I had access to the USB-Creator utility. Nov 24, 2009 at 14:19
  • 1
    Also @Chealion I won't have time to verify your answer as correct anytime soon as I won't be near my Mac for a while (but I do know that Disk Utility was not working for me) If someone else verify's and upvotes, I'll mark as correct. Nov 24, 2009 at 14:19
2

Unetbootin is a tool that installs ISOs on USB keys, or you can use dropdown menus to select distributions right there in the tool.

Slightly easier than doing dd on the command line yourself.

1
  • Unetbootin dates back to 2008 at least. Another answer here already covered this option Jun 12, 2016 at 15:37
1

I have done this frequently on my MacBook Pro for installing OS on new laptops. From my own experience, there is not a single tool that can create bootable USB from all ISO images. You should pick up the right tool for specific ISO file.

Mostly, you should format USB drive to FAT32 first as NTFS is not supported by Mac.

For burning Linux ISO on Mac, UNetbootin is superior than other tools like Etcher. And it consumes less computing resource.

For burning Windows ISO on Mac, UUByte ISO Editor is more efficient and user friendly. In addition, it works seamlessly on latest macOS Big Sur. You can check the tutorial for burning ISO to USB on Mac from here.

For Raspbian PI based ISO for embedded development, balenaEtcher is more recommended.

1
  • you should specify that UUByte ISO Editor is a paid app Mar 7 at 2:31
0

I've user SuperDuper for this task before. It does the job and not much else. Like a good program should :-) The full version is not free ($30) but you get what you need for free:

You can download SuperDuper! v2.6.2 right now and back up and clone your drives for free— forever!

1
  • 6
    Super Duper! doesn't support partitions that aren't formatted as HFS, so it's useless here.
    – rspeed
    Apr 28, 2011 at 20:31

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .