Home > Mac OS X > Using dd to write disk images to CompactFlash disks and floppies under Mac OS X

Using dd to write disk images to CompactFlash disks and floppies under Mac OS X

February 23rd, 2008 Leave a comment Go to comments

Here’s how to use the dd utility to write a disk image to media under Mac OS X. I tested this with 10.5.2 with both a USB to CompactFlash adaptor, and a USB Imation USB SuperDisk.

  1. Plug the media into your Mac.
  2. If you get a message saying that the media cannot be read, click Ignore.
  3. Open Disk Utility (Applications -> Utilities -> Disk Utility).
  4. On the left-hand column, find that disk that you plan to write to. Select any partitions on that disk that are mounted, and click the Unmount button (not the Eject button). Once unmounted, the partitions should grey out.
  5. On the left-hand column, find that disk that you plan to write to, click it, then click on the Info button.
  6. In the window that pops up, note the Disk Identifier. It should be something like disk2 or disk3.
  7. Open up Terminal (Applications -> Utilities -> Terminal).
  8. Type in the following command, replacing diskx with the Disk Identifier found earlier, and image.img with the name of the image file that you wish to read from.

sudo dd if=image.img of=/dev/diskx

Categories: Mac OS X
  1. rschmutz
    December 23rd, 2008 at 15:20 | #1

    Step 3) can be skipped by using the following command in Terminal/shell just before the sudo dd:

    sudo diskutil unmount /dev/diskx

  2. rschmutz
    December 23rd, 2008 at 15:27 | #2

    …sorry hit “submit” too early :)

    if you are using the Terminal/shell anyway, you may skip steps 3, 4, 5 and 6… in Terminal/shell enter:

    mount # check the output for target volume
    sudo diskutil unmount /dev/diskx # use device-path as reported by mount
    sudo dd if=image.img of=/dev/diskx bs=64k

    dd… bs=64k: blocksize 64k speeds up things considerably (on most unixes, that is… experiment with other block-size if you encounter problems)

  1. No trackbacks yet.
You must be logged in to post a comment.