Index / Snippets / Copying files from a failing hard drive

Copying files from a failing hard drive with rsync

Resume interrupted copies and skip unreadable files.

Answers
How do you copy files from a failing hard drive with rsync?
Topics
apple · data · photo · repair
Full article on willem.com
https://willem.com/en/2020-10-15_rescuing-photos-from-a-crashed-imac/

Summary

I use rsync instead of Finder or Explorer to copy from an unreliable disk. It skips unreadable files, resumes where it was interrupted, and with the --exclude option you can route around bad sectors.

Full text

The disk came from a crashed iMac and was already failing. With rsync you copy directory structures like a normal copy, but it skips unreadable files and resumes where it left off after an interruption, which the Finder and Windows Explorer will not do for you. Part way through, the disk started rattling, the copy stalled and errors filled my terminal. I stopped the process to prevent further damage and tried a First Aid file system repair in macOS Disk Utility, without success: the photos from September 2017 stayed unreadable. The fix was rsync's --exclude option. I excluded the damaged September 2017 files and restarted the same command. It resumed, skipped past the bad sectors, and copied everything else without trouble. From about twenty years of photos, only that one month was lost.

Machine formats of this page