In edge computing we use Raspberry Pi, and the operating system is installed in SD. It is very likely that the SD card is damaged due to overheating or other factors, and the SD card must be replaced quickly and then reconnected. At this time we need to back up an SD card.
brew install coreutils
sudo gdd of=/dev/rdisk4 if=sd_backup.dmg status=progress bs=16M
sudo diskutil unmountDisk /dev/disk4
1014 sudo gdd of=/dev/rdisk4 if=sd_backup.dmg status=progress bs=16M