Fsck -fy hangs on Checking catalog file + issues booting (MacBook)

bootcrashhanghard drivesingle-user

Last night my MacBook Pro crashed. This morning I tried turning the computer on, and it had a few issues..

  • Computer doesn't get past initial boot up loading.
  • Fan activates loudly while starting up.
  • Screen is generally slightly tinted green, with light green horizontal stripes going across the display every couple pixels.
  • Initial loading screen has a green progress bar.
  • Screen occasionally has a black stripe with rainbow pixels dotted across the top of the screen.
  • Rendered pixels are generally shifted up or down a single pixel every few inches across the screen.
  • After hanging with a white screen for ~4 minutes, it switches to a blue screen with vertical red stripes.
  • A couple minutes later the computer reboots and the process restarts.

So I try using single-user mode, because obviously I'm not getting anywhere with this boot-up loop.

I follow this process:

$ /sbin/fsck -fy
** /dev/rdisk1
** Root file system
   Executing fsck_hfs (Version hfs-305.10.1).
** Checking Journaled HFS Plujs vloume.
   The volume name is Macintosh HD
** Checking extents overflow tile.
** Checking catalog file.

It proceeds to hang here until I ^C out of fsck.

I try rebuilding the catalog

$ fsck_hfs -y -Rc -d /dev/disk0s2
Unable to open block device /dev/disk0s2: Resource busyjournal_replay(/dev/disk0s2) returned 16
** /dev/rdisk0s2 (NO WRITE)
        Using cacheBlockSize=32K cacheTotalBlock=16384 cacheSize=524288K.
   Executing fsck_hfs (version hfs-305.10.1).
        Block 975093950 is not an MDB or Volume Header
Journal is empty
** Checking JOurnaled HFS Plus volume.
   The volume name is Macintosh HD
** Checking extents overflow file.
** Checking catalog file.
** The volume Macintosh HD was found corrupt and needs to be repaired.
       volume type is pure HFS+
       primary MDB is at block 0 0x00
       alternative MDB is at block 0 0x00
       primary VHB is at block 2 0x02
       alternate VHB is at block 975093950 0x3a1ec0be
       sector size = 512 0x200
       VolumeObject flags = 0x03
       total sectors for volume = 975093952 0x3a1ec0c0
       total sectors for embedded volume = 0 0x00
       CheckHFS returned 7. fsmodified = 0

It says my hard drive is corrupt. To repair the hard drive you generally use /sbin/fsck -fy, right? The only problem is that gives me the same as before, hanging on the catalog file.

I'm not really sure what to do!

Best Answer

When you can't get a clean run of fsck (which you might need to let run for a handful of hours) - then it's time to make a decision:

  • back up what you can/need to and erase the volume
  • seek other software options to attempt repair

In my expereice, if you don't have lots of IO errors (-B option for fsck_hfs) then the erase will restore full function and you can reinstall the OS and restore from backup. I've also not had much luck forcing fsck_hfs to rebuild parts when the plain /sbin/fsck -fy fails - but you could get lucky there with an unusual corruption pattern on this drive.

The second option doesn't have great promise. Disk Warrior seems to be one of the decent utilities to try when fsck won't work - but unless you have lots of specific corruption issues - the time you spend wiping and reinstalling usually doesn't outweigh the cost of that software. It also may or may not work. If Disk Warrior also fails to repair or rebuild the catalog, you're back to the decision point - wipe or escalate to even more expensive / specialized support like opening an engineering ticket with Apple or someone that's able to dump the filesystem structure more deeply for analysis.