If you use
dd for any kind of copying you’ll know how it’s not exactly forthcoming with information and it’s hard to tell if it’s doing anything.
Some versions of
dd have a
status=progress parameter that will output progress information. Sadly this doesn’t exist on the native MacOS version.
An alternative way of showing progress information is to use
pv (or pipe viewer).
First install it with brew:
brew install pv
pv between reading from the
dd source and writing to the
For example, you might write a Raspberry Pi image to an SD card with:
dd if=retropie.img of=/dev/rdisk4
pv you break this into the input and output parts and put
pv in the middle:
dd if=retropie.img | pv | dd of=/dev/rdisk4
Sudo needs to be added to both calls to
sudo dd if=retropie.img | pv | sudo dd of=/dev/rdisk4
pv how much data you are transferring allows it to provide better information, and you can do this with the
-s flag. In this instance the amount of data is the size of the input image, so:
sudo dd if=retropie.img | pv -s `stat -f%s retropie.img` | sudo dd of=/dev/rdisk4
And what is the result of this? You get to see the progress! Useful if you’re transferring a large amount of data.