Disk Erase failed with the error: Couldn’t unmount disk. Running Mavericks

I am running Mavericks OX 10.9.1 and am trying to erase an external hard drive that has been partioned. I keep coming up with the error message "Disk Erase failed with the error: Couldn’t unmount disk." Any suggestions?

iMac, OS X Mavericks (10.9.1)

Posted on Jan 21, 2014 1:45 PM

Reply
49 replies

Jan 21, 2014 3:17 PM in response to Kappy

sorry, I should clarify. I was able to eject the external HD, but after waiting a few minutes and reconnecting it, I was still not able to erase the external hard drive.


I also tried to erase the drive after a simple restart of the computer. That did not work.


When I restarted the computer with command + r at the chime, the menu came up, but did not have the option of "Recovery HD".


I can try again and tell you what my options are if that will help...

May 11, 2016 4:37 PM in response to studio_

I had this problem with a 2TB external Seagate disk. I thought the disk was just plain dead.


DiskUility could not repair it, which was fine. It's just a backup disk. But I wanted to repartition it.


BUT, it would not mount, and it would not unmount, by any means, force or not. It was in a kind of sad HD limbo.


Turning off Spotlight did not help either. (BTW, I think it was Spotlight (in conjunction with TimeMachine) which caused the problem to begin with.)


But what did help, after turning off Spotlight, was to kill a crazy fsck_hfs process that was hitting the disk in question so that DiskUtility could not unmount it.


ps -ax | grep fsck

sudo kill <process number>


where "<process number>" is the actual process number returned by ps. I found that solution here. And it works! read that whole thread.


Alternatively, you could probably also kill that crazy fsck_hfs process in Activity Monitor, where you will see it eating up your CPU.


After you kill it, then launch DiskUtility and it will now successfully unmount the disk and let you repartition it (or whatever).


BTW, I think the preferred way to turn Spotlight On/Off is a little more graceful than using the mdutil command.


Try this instead, to turn it off:


sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.metadata.mds.plist


and then just turn it back on again when done:


sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.metadata.mds.plist


In summary, there are steps in this fix:


1.) turn off Spotlight;

2.) kill the fsck_hfs process;

3.) launch DiskUtility and format the disk;

4.) turn ON spotlight;

5.) restart is probably a good idea.

Mar 29, 2017 8:46 PM in response to studio_

Hi, I've just solved the same problem successful 100%.

Step 1: Right after turn macbook on, press "Option-Command-P-R" to Reset NVRAM (See more Startup key combinations for Mac - Apple Support)

Step 2: Fix with USB Boot Drive (find how to create USB Boot https://www.youtube.com/watch?v=W7bPfNREVMU)

Step 3: Select Hardrive you want to fix + select First aid tab + "Verify" and "Repair"

Step 4: Press "Command + R" to reinstall normally.

Be successful!

Oct 28, 2015 11:47 AM in response to studio_

I just had this problem, while erasing the hard disk from my El Capitan install USB drive.


I checked this page and it suggested, correctly, that the drive was not unmounting properly.


Rather than using Terminal, there is a much simpler solution:

  1. In Disk Utility Click the hard disk NAME (eg. Macintosh HD) on the left hand list - not the drive itself (eg. Toshiba1234 or Samsung1234).
  2. Click on the Mount tab and Unmount the drive. The name on the left should go grey.
  3. You should now be able to select the drive and erase it.


Worked for me!
Simon 🙂

Jan 21, 2014 2:17 PM in response to studio_

There must be something on the drive that has a connection to the internal drive, I think. Try booting from the Recovery HD:


Boot to the Recovery HD:


Restart the computer and after the chime press and hold down the COMMAND and R keys until the menu screen appears. Alternatively, restart the computer and after the chime press and hold down the OPTION key until the boot manager screen appears. Select the Recovery HD and click on the arrow button below the icon.


Select Disk Utility from the list and click on the Continue button. See if this lets you erase the drive.

Jan 21, 2014 2:26 PM in response to studio_

To list all the drives and their accompanying partitions from the Terminal, type the following command:


diskutil list


This will give you a listing out the drives, their volume names, the size of the drive and partitions, their partition types, and their identifier location. Paste the disk drives listing into a reply to this message.




Jan 21, 2014 3:21 PM in response to Dr.Mac.

#: TYPE NAME SIZE IDENTIFIER

0: GUID_partition_scheme *2.0 TB disk0

1: EFI EFI 209.7 MB disk0s1

2: Apple_HFS OSX 869.3 GB disk0s2

3: Apple_Boot Recovery HD 650.0 MB disk0s3

4: Apple_HFS TAGP 1.1 TB disk0s4

5: Apple_HFS Scratch 49.8 GB disk0s5

/dev/disk1

#: TYPE NAME SIZE IDENTIFIER

0: GUID_partition_scheme *1.0 TB disk1

1: EFI EFI 209.7 MB disk1s1

2: Apple_HFS Production iMac Clone 250.0 GB disk1s2

3: Apple_HFS Production iMac Time... 749.7 GB disk1s3

Jan 21, 2014 3:21 PM in response to studio_

Here's a suggestion you might try:


It appeared that the external drive would not unmount because some activity was using it. fsck_hfs process was working away as shown by activity monitor. It seems that Spotlight was struggling with a the failed drive and would not let it go so the unmount and erase could not occur.

This was solved by disabling Spotlight (terminal: sudo mdutil -a -i off) temporarily. After disabling Spotlight, Disk Utility performed its job and my corrupted drive was restored to use.


(Spotlight is turned back on with: sudo mdutil -a -i on)


This is from a 2012 discussion re: this problem. It helped some users, so give it a go.

Jan 21, 2014 3:31 PM in response to Kappy

Thank you!! This worked. I also turned off Time Machine, as I had set this drive to be the ** for Time Machine (but because of the partion, did not have enough free space). I suppose a better techy (than myself) would have seen that right away, but with your post Kappy, I was able to fix it! Thanks so much Kappy and Dr. Mac!

Mar 29, 2014 7:48 PM in response to studio_

I am running Mavericks 10.9.2 and am having the same problem, but am unable to fix it with the help suggested by Kappy and Dr.Mac. Specifically, I have a WD Passport external hard drive (formatted FAT) with a single partition that doesn't show up in Finder when I plug in the HD. I can find the disk in Disk Utility, but cannot repair it, eject it, or unmount it when I try to erase and/or re-partition the disk.


Things I have tried: unplugging the HD and plugging back in, restarting my computer, restarting and holding command+r to enter disk utility, entering Terminal and typing "diskutil unmountDisk force disk1", disabling Spotlight in Terminal ("sudo mdutil -a -i off") then trying to force disk unmounting (above command and "sudo diskutil unmountDisk force disk1")


....and still the disk will not unmount! What should I do?


BTW, here is the response in Terminal after the command diskutil list:

/dev/disk0

#: TYPE NAME SIZE IDENTIFIER

0: GUID_partition_scheme *500.1 GB disk0

1: EFI EFI 209.7 MB disk0s1

2: Apple_HFS Macintosh HD 499.2 GB disk0s2

3: Apple_Boot Recovery HD 650.0 MB disk0s3

/dev/disk1

#: TYPE NAME SIZE IDENTIFIER

0: FDisk_partition_scheme *1.0 TB disk1

1: DOS_FAT_32 BEAVER 1.0 TB disk1s1

May 29, 2014 9:51 AM in response to satxusa

Just had the same issue (yesterday) with USB drive (USB3.0) would not un-mount that had a (2nd) Time Machine backup on it.


I actually thought the disk died, because I just tuned off the power to the disk (I know it's not a good idea to power down without un-mounting). When I powered the disk back up the drive would not mount even after a restart. I took the disk out of the Voyager S3 and put it into a external enclosure and bam the disk was working again. I repaired the disk (using DU Repair Disk, no errors) and put it back into the Voyager S3 and the disk is fine now.


So I have NO idea what happen other than a possible Maverick bug of some sort.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Disk Erase failed with the error: Couldn’t unmount disk. Running Mavericks

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.