Repairing a Corrupted Mac OSX ExFAT Partition

ExFATI run a MacBook Pro Retina (late 2013) and on my 512GB hard drive I have 3 partitions

  • 150GB Mac OSX partition (currently running Mavericks)
  • 150GB Windows 8.1 partition (via Bootcamp)
  • 200GB data parition (formatted with ExFAT)

I chose an ExFAT partition so I could read and write to the data partition from either the OSX or the Windows partition as I use each operating system a similar amount. I had planned to install VMWare fusion at some point to avoid the dual boot, but haven’t sone so due to some licencing issues with some software on my Windows partition that I uncovered in the trial.

Recently I was travelling and was doing some editing for my podcast on the plane. I also inadvertantly moved and deleted some files. The next morning I woke up to deliver a workshop to find that my data partition was missing. Windows reported that the drive needed to be formatted and Mac OSX reported that the drive was corrupt. On either operating system, the relevant disk utilities were unable to fix the issue.

It appears that ExFAT partitions are not well supported in OSX, particularly if you delete files. Unfortunately due to Windows and Mac not playing nicely from a read/write perspective, neither HFS or NTFS are an option for this drive either.

A bunch of articles seemed to indicate that CHKDSK /F on the volume should fix it, but given the fact that Windows was reporting the partition needed to be formatted, this fix was not valid in this circumstance. After searching the web for numerous reports and fixes (and tearing my hair out with worry in the process), I finally stumbled on an article that led to a simple solution of a terminal command:

sudo fsck_exfat -d disk0s4

where diskos4 is your ExFAT partition.

It then asks:

Main boot region needs to be updated. Yes/No?

to which you reply Yes. You can then run repair in the OSX Disk Utility and the partition should be restored!

Easy fix, but baffles me why ExFAT and NTFS support is so bad on Mac OSX.

Advertisements

28 thoughts on “Repairing a Corrupted Mac OSX ExFAT Partition

  1. That terminal command worked for me, didn’t even have to fix in disk util, just enter that and restart computer. This has happened a couple times and it’s soooo annoying, so thank you for the fix!

  2. You sir saved me today! I’m sharing a video project with a Windows user so I decided to use EXFAT format and today I had 500 gigs of media appear to be gone. Followed the simple Terminal command and fixed it. After unhooking replugging it in the drive came back intact. I need to find a better way to deal with sharing with a PC user. Thanks again!.

    Erik

  3. Just remember, exFAT is an EXTENDED version of the FAT system… …It is still dependent on several files, MBR, the MFT, and also a Partition Descriptor. If any of these become damaged, or receive a command that they cannot process fully, or if bad sectors occur you’ll be stuck. Maintenance, people. Maintenance. The standard maintain functions work while the MBR is stable and the MFT is okay. But if you’re like me and move a lot of files, those get a little beat up. Running the fsck command is a way to rebuild them or check them, and make the rest of the utilities available for use, I suggest you run them to prevent more damage.

  4. It work! You save my day. Was shock to learn that my ExFAT partition gone upon MAC startup this morning and was panicked for a while until I found your solution for it. Big thanks!

  5. Another tip I discovered:

    When you run fsck_exfat on your drive and it comes up “Resource Busy” you can use the following commands:

    This will give you a list of processes using your disk:
    ps -ax | grep disk2 (but your disk)

    You will get something like this:
    13699 ?? 11:52.83 /System/Library/Filesystems/hfs.fs/Contents/Resources/./fsck_hfs -y /dev/disk2s2

    Run this to kill that process
    sudo kill 13699

    Repeat until it lets you fsck_exfat your drive 🙂

  6. Seriously thanks for this post, you just saved about 4 years worth of work….I entered the command in Terminal and the disk just showed right back up like normal.

  7. Hi Craig,

    I have the exact same Macbook model and I have partitioned my hard drive exactly the same way as yours (honestly, I find the resemblance a little eerie 😀 ).

    Unlike you, I wasn’t as fortunate. OS X corrupted my ExFAT partition twice and on both accounts, “sudo fsck_exfat -d disk0s4” didn’t do the trick for me.

    I finally resorted to formatting my shared partition in NTFS and using Paragon NTFS to access the shared partition. However, I am still not really satisfied with this arrangement because I hibernate my windows partition a lot and there are some issues with files missing if OS X were to write to a partition that is hibernated.

    I would just like to know:

    1) If you are still using ExFAT for your shared partition?
    2) If you are not, what is the current configuration?

    Cheers.

    • Wayne,

      I am still using the same configuration as the post, although I tiptoe when using any shared data. I had shyed away from Paragon but perhaps I should reconsider it at some stage. Still havent found a perfect solution.

      Craig

  8. This solution doesn’t work for me, simply because I get the error: “Can’t open ____ (my hard drive name). No such file or directory.” Is it possible that the name I gave my drive is making it impossible for this command to execute properly? The drive is mounted (read only, the problem I’m trying to fix), and I’m not misspelling it. Any help is greatly appreciated!

  9. Hello!
    has anyone done a UDF Hard Disk (no partition or only pseudo partition table) ?
    Won’t work on a real internal volume, of course, but perhaps on a image file on some exfat partition.

    Have read:
    https://github.com/JElchison/format-udf#os-support
    and
    https://j0nam1el.wordpress.com/2015/02/20/sharing-a-hardflash-drive-across-windows-os-x-and-linux-with-udf/

    Looks cool, modern, Trans-OS and open to me.
    Only drawback ist, that neither Apple nor M$ do advertise it. But what do we expect 😉 ?

    Yours!

    AndiSho

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s