3

I've been backing up my Mac with Time Machine on an external hard drive for several years. I recently plugged the external drive into my Mac, it spent a long time running fsck_hfs and finally showed this dialog:

Running disk utility gives a lot of Invalid extent entry messages along with the conclusion First Aid process has failed.

My intuition would be to copy the whole disk to a new drive. I have a vague recollection from learning about Time Machine several years ago that this would have to be block-wise in order to preserve the Time Machine backup (using dd or carbon copy cloner, right?). But presumably a block-wise copy of the drive would copy the extent errors as well? So do I just have to give up and lose my entire Time Machine history at this point?

4 Answers 4

1

Time Machine makes extensive use of hard (as opposed to symbolic) links (for eg "this folder is the same as yesterday's backup"). See eg http://www.baligu.com/pondini/TM/Works.html.

I thought the issue with copying backup history was that many copy tools won't see the hard links, so you end up with multiple copies rather than links and run out of space, hence your recollections about doing a block level copy instead.

But now I look it up, apparently Finder can copy a Backups.backupdb folder correctly. See eg http://www.baligu.com/pondini/TM/18.html (which is sadly a little out of date), and Apple's current documentation https://support.apple.com/en-gb/HT202380.

The message in your first screen shot says "You can still open or copy files on the disk, but you can't save changes to files on the disk". So perhaps you will be able to follow the instructions above to copy your Backups.backupdb folder (containing your backup history) to a different drive.

0

I have found a very quick and simple solution not involving terminal commands:

Simply choose unmount again. The drive will no longer appear as a choice in First Aid.

Then physically disconnect the drive.

Then plug the drive back in.

Once it appears again as an available drive n Disk Utility, run First Aid Again. This time, the process will take longer, because each snapshot on the drive is checked in its numerical sequence. For me, there were 18 snapshots, and each one took about 20 to 30 seconds. Once they were all complete, the "failed" message no longer appears, only the "successfully completed" message appears."

Apparently all that was needed was to go through the unmount, disconnect drive from mac, re-connect, then re-mount sequence in First Aid, all in that correct order to restore some short missing string in the command that First Aid uses on a newly mounted mounted disc that HAS JUST BEEN PLUGGED BACK IN. There is undoubtedly some terminal command that does this also, but I cannot find it. But it is unnecessary. The process merely requires that the unmount/re-mount sequence is done in the proper order. In the past, to solve the problem, I erased the external drive, re-named and re-chose it as a Time Machine Backup and went through a complete initial backup to be sure that the backup disc was sound. That was a waste of time. This simple process fixes the problem without doing that. This problem always occurs following an accidental un-plugging of the external drive from the port without using First Aid's UNMOUNT command first. Prior to this, I attempted to unmount and re-mount using the commands in First Aid, and it never worked. The First Aid unmount command has to be followed by physically disconnecting the drive, waiting several seconds, plugging the drive back in, waiting until it re-appears as a choice in Disk Utility, and then trying the repair disc command again.

1
  • Fascinating - I wonder if it's a bug where the unclean dismount flag gets over written and then the tool somehow can see the drive correctly?
    – bmike
    Commented May 1, 2023 at 14:53
0

It's interesting. It re-occurred last nignt. So, I ran first aid on the entire disc, and it was fine. Then I ran it on the container, and it showed that it required repair and started the repair, running through all the images on the disc and then showing success. Then I re-ran first aid on the volume, and it was successful. So, whatever that means. I guess the container needed its own repair before the volume was repaired. I hope that fixes it next time the drive gets accidentally unplugged. I don't like the mini C usb connectors. The become disconnected too easily on a minor tug. I am going to unmount the drive every time it completes a backup and then just re-mount for daily backups. That way, disconnecting "improperly" will not be a problem. Good thing I found it. It saved me from buying a new external drive. Being careful, I have been running a weekly Carbon Copy Cloner backup each week on another drive, anyway.

0

Better and more reproducible solution: Use Disk Utility to initially run First Aid on the Container disk. After that succeeds, run it on the volume, itself. Works for me. Voila' !

1
  • Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.
    – Thinkr
    Commented May 6, 2023 at 19:50

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .