# insert SD and find out where it is mounted diskutil list # /dev/disk0 # #: TYPE NAME SIZE IDENTIFIER # 0: GUID_partition_scheme *250.1 GB disk0 # ... # /dev/disk1 # #: TYPE NAME SIZE IDENTIFIER # 0: FDisk_partition_scheme *15.7 GB disk1 # ... sudo dd if=/dev/rdisk1 bs=1m | gzip > ~/Desktop/sdcard.img.gz # or if you don't want to compress it: # sudo dd if=/dev/rdisk1 of=~/Desktop/sdcard.img bs=1m # to restore it, firn unmout the SD diskutil unmountDisk /dev/disk1 gzip -dc ~/Desktop/sdcard.img.gz | sudo dd of=/dev/rdisk1 bs=1m # or if it is not compress: # sudo dd if=~/Desktop/sdcard.img of=/dev/rdisk1 bs=1m