Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Fix corrupted exFAT disk macOS/OSX

exFAT support on macOS seems to have some bugs because my external drives with exFAT formatting will randomly get corrupted.

Disk Utility is unable to repair this at first, but the fix is this:

  1. Use diskutil list to find the right drive id.
  2. You want the id under the IDENTIFIER column, it should look like disk1s1
  3. Run sudo fsck_exfat -d <id from above>. eg sudo fsck_exfat -d disk1s3
  4. -d is debug so you'll see all your files output as they're processed.
  5. Answer YES if it gives you the prompt Main boot region needs to be updated. Yes/No?
  6. Open Disk Utility and you should be able to repair here successfully.

See the apple man page below for details on the fsck_exfat utility.

Sources/Extra Reading: https://developer.apple.com/legacy/library/documentation/Darwin/Reference/ManPages/man8/fsck_exfat.8.html https://craigsmith.id.au/2014/07/06/repairing-a-corrupted-mac-osx-exfat-partition/ https://discussions.apple.com/thread/4154638?tstart=0

@Alex-Swann

This comment has been minimized.

Copy link

Alex-Swann commented Jun 14, 2018

Thanks man. This saved me being suckered into a $80 disk recovery app.

@ashutoshdesign

This comment has been minimized.

Copy link

ashutoshdesign commented Aug 24, 2018

I'm getting an error saying- "Can't open /dev/rdisk2s2: Resource Busy". What do I do?

@michaelmruta

This comment has been minimized.

Copy link

michaelmruta commented Sep 2, 2018

@ashutoshdesign you can try doing the command in single-user mode by holding ⌘+S on boot-up just after pressing the power button of your mac.

@sriharshachilakapati

This comment has been minimized.

Copy link

sriharshachilakapati commented Sep 25, 2018

I'm getting this error:

21 clusters were marked used, but not referenced
0 clusters were marked used and CLUST_BAD
3 clusters were marked free, but referenced
** Rechecking main boot region.
** Rechecking alternate boot region.
Write     offset = 0x000003c00000  length = 0x020000
fsck_exfat: Couldn't write 131072 bytes at offset 62914560: Bad file descriptor

What should I do?

@sriharshachilakapati

This comment has been minimized.

Copy link

sriharshachilakapati commented Sep 25, 2018

EDIT: If you ever happen to find my error, just ignore that and go to Disk Utility. It should now repair fine.

It appears to be stuck, but actually works. Took 30 minutes to repair my 2TB external HDD from Seagate.

@occupiedUsername

This comment has been minimized.

Copy link

occupiedUsername commented Jan 4, 2019

@ashutoshdesign you can try doing the command in single-user mode by holding ⌘+S on boot-up just after pressing the power button of your mac.

This worked for me.

THANK YOU!

@Mathy5

This comment has been minimized.

Copy link

Mathy5 commented Jan 19, 2019

Hi guys! After had typed “sudo fsck_exfat -d disk1s1” in single-user mode my Mac is working for like 9h till now. Ok the hdd has inside like 1.2T of 2T but, damn...

@simonjpartridge

This comment has been minimized.

Copy link

simonjpartridge commented Feb 12, 2019

To fix the error "Can't open /dev/rdisk2s2: Resource Busy". you can download and launch Disk Arbitrator to prevent the disk from being mounted when is is plugged in.

@djruess

This comment has been minimized.

Copy link

djruess commented Mar 6, 2019

Thank you @scottopell This solved my problem!

@cheTesta

This comment has been minimized.

Copy link

cheTesta commented Mar 19, 2019

Or @djruess eventually, you could run the above mentioned commands in terminal entering in macOS recovery mode, opening terminal from there!

@davur

This comment has been minimized.

Copy link

davur commented Apr 3, 2019

I'm getting an error saying- "Can't open /dev/rdisk2s2: Resource Busy". What do I do?

I was stuck with "Resource Busy" too, but a comment on the Source link (on craigsmith.id.au) describes how to find and kill the process locking the resource which worked for me.

ps -ax | grep disk2 (but your disk)
13699 ?? 11:52.83 /System/Library/Filesystems/hfs.fs/Contents/Resources/./fsck_hfs -y /dev/disk2s2

sudo kill 13699

Once the offending process is killed, I got an OS prompt about an error mounting the drive (something along the lines of it being mounted in read only mode, don't remember the wording). After that the drive mounted in Finder and Disk Utility and I was able to run "First Aid" using "Disk Utility"

@Seluj78

This comment has been minimized.

Copy link

Seluj78 commented Apr 25, 2019

I am running the sudo fsck_exfat -d on my 4TB drive. Hopefully it won't take too long

@bcomnes

This comment has been minimized.

Copy link

bcomnes commented May 18, 2019

It works, but it takes a long time

@yogesh2jadhav

This comment has been minimized.

Copy link

yogesh2jadhav commented Jun 3, 2019

Apples-MacBook-Pro:/ Yogesh$ sudo fsck_exfat -d disk3s1
Opening /dev/rdisk3s1
** Checking volume.
** Checking main boot region.
fsck_exfat: Invalid jump or signature
Main boot region is invalid. Trying alternate boot region.
** Checking alternate boot region.
fsck_exfat: Invalid jump or signature
Alternate boot region is invalid.
** The volume could not be verified completely.

What to do in such case...?

@tfkproject

This comment has been minimized.

Copy link

tfkproject commented Jun 5, 2019

Apples-MacBook-Pro:/ Yogesh$ sudo fsck_exfat -d disk3s1
Opening /dev/rdisk3s1
** Checking volume.
** Checking main boot region.
fsck_exfat: Invalid jump or signature
Main boot region is invalid. Trying alternate boot region.
** Checking alternate boot region.
fsck_exfat: Invalid jump or signature
Alternate boot region is invalid.
** The volume could not be verified completely.

What to do in such case...?

I got same problem here. What should I do?

@cowteets

This comment has been minimized.

Copy link

cowteets commented Jul 14, 2019

I keep getting stuck at the "** Checking main boot region" portion

after working for a few min i get a "Could Not Read Boot Region" error, every time.
Anyone else? Help?

@ronylucca

This comment has been minimized.

Copy link

ronylucca commented Aug 18, 2019

I've got 'Invalid jump or signature' but when I tried to mount got success. Problem solved. Probably some process was blocking the drive even after reboot.
Thanks man!

@bcbrendan

This comment has been minimized.

Copy link

bcbrendan commented Sep 5, 2019

I keep getting stuck at the "** Checking main boot region" portion

after working for a few min i get a "Could Not Read Boot Region" error, every time.
Anyone else? Help?

I get this, too. Very frustrating.

Opening /dev/rdisk5s3 ** Checking volume. ** Checking main boot region. fsck_exfat: Could not read boot region ** The volume could not be verified completely.

With that said, my TV is no longer able to access the drive, either—this is a HDD that I use for storing movies, etc.—so I'm equally concerned that the drive could be damaged.

@dghein

This comment has been minimized.

Copy link

dghein commented Sep 7, 2019

happening on brand new thumb drive for some reason was read only out of the box. same deal with a terabyte hard drive. any format, fat32, exfat, macos journaled, etc. is unwritable. tried creating directories and modifying permissons in /Volumes/ also with no luck. any suggestions would be appreciated!

@windhost

This comment has been minimized.

Copy link

windhost commented Oct 13, 2019

got it too

** Checking volume.
** Checking main boot region.
fsck_exfat: Invalid jump or signature
   Main boot region is invalid. Trying alternate boot region.
** Checking alternate boot region.
fsck_exfat: Invalid jump or signature
   Alternate boot region is invalid.
** The volume  could not be verified completely.
@WeijieZhu0204

This comment has been minimized.

Copy link

WeijieZhu0204 commented Nov 8, 2019

awesome work!

@SikSo1897

This comment has been minimized.

Copy link

SikSo1897 commented Nov 19, 2019

thx ☺️ you saved me

@yogesh2jadhav

This comment has been minimized.

Copy link

yogesh2jadhav commented Nov 19, 2019

Sikso1897 and WeijieZhu0204 which commands helped u?

@pkorson

This comment has been minimized.

Copy link

pkorson commented Nov 30, 2019

Just wanted to say thanks. Took less than 10min for me to get my 8tb external back.

@PrasannaBrabourame

This comment has been minimized.

Copy link

PrasannaBrabourame commented Dec 3, 2019

When i tried the above command i am getting response as
fsck_exfat: Can't open /dev/rdisk2s2: Resource busy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.