Raspberry Pi How To: Write image file to/from SD Card using macOSX

After downloading a RaPi image the image must be transferred to a memory card.

The memory card must be a class 10 (fast card) for any of the D-Star hotspot / repeater images.

On an Mac you can use Terminal to perform the transfer.

Start with this command to discover all disks (the memory card is treated as a disk):

diskutil list

In this example we assume disk3 is the memory card.
Unmount the memory card:

diskutil unmountDisk /dev/disk3
diskutil unmountDisk /dev/rdisk3

Now write the image to the card:

sudo dd bs=1m if=/Path/To/Image/File of=/dev/rdisk3

The write process will take quite some time and during this time there is no output on the terminal - just be patient and wait. Writing to rdisk3 is much faster than writing to disk3. When the write process is completed the terminal will report a successful write and return to the command prompt.

After write is finished the boot partition on the SD card should mount automatically. It should be ejected before removing the card.

By default the SSH server on the RaPi is disabled. If you intend to start your RaPi without a display you need to go to the boot partition and create an empty file named "ssh" to enable the SSH server on the Pi:

sudo touch /Volumes/boot/ssh

The dd command is also handy to backup your working image so you have a copy ready when your SD card fails or some other mishap occurs. Here is the command line to create a backup:

sudo dd bs=1m if=/dev/disk1 of=/Path/To/Image/File

Typically you would back up to your desktop with a command line similar to this:

sudo dd bs=1m if=/dev/disk1 of=/Users/your_short_user_name/Desktop/rapi_backup.img

If you are unsure of your Short user name you can look it up with Finder as per image below - your short user name is located to the right of house symbol (circled in red below).

Short User Name in Finder
Short User Name in Finder