Disk Utility usually works trouble-free, but a frustrating “Couldn’t Unmount Disk” error can halt whatever the attempted task is right in its tracks. This can happen during partitioning, disk verification and repair, and even during formatting, and there’s usually little to no additional information provided as to how to resolve the problem or even what the problem is.
Typically the “Couldn’t Unmount Disk” error pops up when the currently boot drive is being modified, thus the easiest solution is to boot from another drive and run Disk Utility from there instead. For the boot drive, it shouldn’t matter which version of OS X it’s for (assuming 10.7, 10.8, and 10.9 at least), the only requirement is that it has Disk Utility – which they all do. This will allow you to fix the problem, regardless of the cause, by one of two means, the first is a sure-thing to fix the issue, while the other only works sometimes. We’ll cover both with a bit of explanation.
Resolve the Unmount Error with a USB Boot Drive
This is the recommended method because it should always fix the error. You will need any OS X boot drive to complete this task, I used a Mavericks boot installer drive for this purpose but others should work too, whether they are installation drives or just recovery drives, the important thing is they are bootable and separate from the primary boot disk that stores the installed OS:
Attach the USB boot drive to the Mac and reboot
Hold down the OPTION key during boot, then select the attached boot drive (typically has an orange icon at the boot menu)
At the boot menu, choose “Disk Utility” (if using an Installer disk, pull down the “Utilities” menu to access Disk Utility)
Go to “First Aid” and verify the disk, then repair if needed
Now perform the original task that threw the “Couldn’t Unmount” error
I ran into this twice recently, first when attempting to modify partitions on a drive, which came right along with a separate “partition failed” error, and again was triggered when attempting to format those partitions. The above steps did the trick and everything was working again as expected.
This is a good example of why it’s very valuable to have a bootable USB thumb drive set up with whatever version of OS X is running on your Macs, because without a separate boot drive some of these errors would be unresolvable. Such boot drives are easy to create on your own, here are instructions for making boot disks for OS X 10.9, OS X 10.8, and OS X 10.7. For older Macs running prior versions of OS X, typically anything running OS X 10.6 or earlier will have a SuperDrive, and thus shipped with a bootable DVD that can serve this same purpose.
Fixing Disk Utility Errors via Recovery Partition
If the Unable to Unmount Error is triggered by first aid or formatting a non-boot partition, you may be able to fix the error by booting from the Recovery partition that is included with all new versions of OS X. This will not work if the error was triggered by attempting to modify the boot disk through partitions or formatting, and you will need to use the method above instead.
Reboot the Mac holding down the “Option” key and choose the Recovery partition
Select “Disk Utility” from the boot menu
Go to “First Aid” to verify and repair the disk, or go to “Erase” to format the disk
Again, if the disk throwing the errors is the same as the primary boot partition that Recovery is also on, the above method may not work to resolve the problem. In that case, you’ll need to boot from a separate USB drive to fix the error.