GNU ddrescue for hard disk imaging or recovery on macOS Ventura
GNU ddrescue (ddrescue) is a proven data recovery tool which you can trust. However, it is also quite a complicated command line tool. If only there was a way to make it more straightforward to use.
GNU ddrescue is a data recovery tool. It copies data from one file or block device (hard disc, cdrom, etc) to another, trying to rescue the good parts first in case of read errors.
ddrescue is an essential tool for data recovery originally released in 2004 and consistently updatedover time. As is often the case your Linux distribution might be a little behind the upstream release. Ubuntu 24.04 LTS has release 1.27 which is only a little behind the current release, but for LTS users I would recommend sticking with the release provided with the LTS distribution unless you absolutely know you need a fix made in the current release.
Using ddrescue safely
You probably came here because of a data recovery issue. Please read these three important points or risk losing your data!
With any tool capable of erasing data, there is the opportunity to make a mistake that results in the source data being damaged. You should allow the tools you run to finish, avoid running them on mounted partitions and never try to repair data on suspected damaged drives. In this case unmount the drive if you mounted it and try to recover an image of all you can onto a new good drive, ideally of the same capacity and form factor if it is destined to be a replacement for a broken computer.
Allow tools to finish!
Patience is a virtue. Some tools can take an extraordinarily long time to run. Let them!
Don't run tools on mounted partitions
Mounted partitions make a disk available to use. Unmounted disks are safe to run low level tools on.
Don't try to repair damaged drives
Make as good a copy of a damaged drive and then try to repair the copy. Damaged drives should be retired.
You should take care to remember that any data on a chosen destination will be replaced. This is why it can be helpful to have the DDRescue-GUI and optionally, GParted, to provide a better visual check before you might destroy the existing data on a destination drive!
GNU ddrescue is like any other power tool. You need to understand what it does, and you need to understand some things about the machines it does those things to, in order to use it safely.
Never try to rescue a r/w mounted partition. The resulting copy may be useless. It is best that the device or partition to be rescued is not mounted at all, not even read-only.
Never try to repair a file system on a drive with I/O errors; you will probably lose even more data.
If you use a device or a partition as destination, any data stored there will be overwritten.
Some systems may change device names on reboot (e.g. udev enabled systems). If you reboot, check the device names before restarting ddrescue.
If you interrupt the rescue and then reboot, any partially copied partitions should be hidden before allowing them to be touched by any operating system that tries to mount and "fix" the partitions it sees.
DDRescue-GUI helps users recover important data fast, using GNU ddrescue but without having to understand the command line, which can be daunting.
DDRescue-GUI
DDRescue-GUI is now a commercial software package available for Windows, macOS and various Linux distributions and releases.
To find out more about DDRescue-GUI, head to https://www.hamishmb.com/ddrescue-gui/
DDRescue-GUI installer is not notarised for macOS
DDRescue-GUI Drag and drop installer
DDRescue-GUI isn't notarised
I'd expect any commercial software for macOS to be notarised so that the software can install properly without warning. It is disappointing that it is not.
DDRescue-GUI looks identical on macOS to Linux
DDRescue-GUI doesn't hide the complexity of the macOS disk devices
macOS Disk layouts are complex, and this tool is very low level
Proceed with extreme caution on macOS. Make absolutely sure you know you are using the right partitions!
You can use the command line % diskutil list to see everything from macOS perspective. Note that this command and DDRescue-GUI show all devices, containers, images in their raw form.
% diskutil list
/dev/disk0 (internal, physical):
#: TYPE NAME SIZE IDENTIFIER
0: GUID_partition_scheme *1.0 TB disk0
1: Apple_APFS_ISC Container disk1 524.3 MB disk0s1
2: Apple_APFS Container disk3 994.7 GB disk0s2
3: Apple_APFS_Recovery Container disk2 5.4 GB disk0s3
/dev/disk3 (synthesized):
#: TYPE NAME SIZE IDENTIFIER
0: APFS Container Scheme - +994.7 GB disk3
Physical Store disk0s2
1: APFS Volume Macintosh HD 10.2 GB disk3s1
2: APFS Snapshot com.apple.os.update-... 10.2 GB disk3s1s1
3: APFS Volume Preboot 6.2 GB disk3s2
4: APFS Volume Recovery 935.4 MB disk3s3
5: APFS Volume Data 636.4 GB disk3s5
6: APFS Volume VM 20.5 KB disk3s6
/dev/disk4 (disk image):
#: TYPE NAME SIZE IDENTIFIER
0: GUID_partition_scheme +3.8 GB disk4
1: Apple_APFS Container disk5 3.8 GB disk4s1
...
/dev/disk19 (disk image):
#: TYPE NAME SIZE IDENTIFIER
0: GUID_partition_scheme +100.0 MB disk19
1: Apple_HFS Install DDRescue-GUI 100.0 MB disk19s1