Installing Windows on a Mac, getting “Your disk could not be partitioned” error

The problem

Installing Windows 10 using the Boot Camp Assistant app, but each time the app gets to the partitioning step it errors out saying “Your disk could not be partitioned”, suggesting “run Disk Utility to check and fix the error”.

You’ve tried running Disk Utility but the error still persists. Here is what fixed it for me, there are some other possible solutions at the end of the article.

Possible solution

If you are using Time Machine to backup your Mac, then clearing out all your local snapshots could fix this.

Make sure to do a Time Machine backup in case something bad happens here or with the Windows install.

1, In System Preferences, untick “Back Up Automatically” in the Time Machine preference

2, Run this command in the Terminal app;

tmutil thinlocalsnapshots / 9999999999999999

basically, it will remove all the local backups on your boot drive, it won’t delete any of your files on your Time Machine backup drive.

3, Once the command finishes, start the Boot Camp Assistant app and try again, it should work now.

4, When you have Windows installed remember to re-enable Time Machine on the Mac side.

Not sure if this is related or not, but my boot drive at the time was formatted as APFS and I was on High Sierra 13.1

 

A little bit about the tmutil command:

tmutil thinlocalsnapshots <mount_point> [purge_amount] [urgency]

The <mount_point> is which drive you’d like cleaned.

The [purgeamount] is the amount of space you want to recover. (optional)

The [urgency] part is a number between 1 – 4, on how quickly you want the space recovered. (optional)

 

Other possible solutions:

  • The first obvious fix is to run First Aid in Disk Utility if you haven’t yet. (run it at boot)
  • Run a filesystem consistency check (/sbin/fsck -fy) during boot, see instructions here or here.
  • If you’re low on disk space, freeing up some might help.
  • If none of this helps, and you can’t find anything else to try online, then your only option left is to backup and reinstall;
    1. Backup everything via Time Machine
    2. Boot into Internet Recovery (hold down Command (⌘) + Option + R at boot)
    3. Erase your whole internal disk (not just the partition)
    4. Install a fresh copy of macOS and install any Mac updates
    5. Run Boot Camp Assistant and partition your drive + install Windows BEFORE restoring all your Mac data.

Feel free to leave comments if you get stuck, or find other solutions to this error.

Source: Apple discussions

Posted in Mac.
  • Boca

    This garbage doesn’t even work. Thanks for nothing, maybe you should address the real issue of AFPS drives, High Sierra, and Boot Camp.

    • https://adriel.co.nz Adriel

      Hi Boca, I’m sorry that it doesn’t work, I know how frustrating this can be as I had this issue last week, and in the end this is what fixed it for me. Figured it might help others to post it, as it took me a while to come to this fix.
      If it doesn’t work for you, then I’m sorry, go try the other suggestions around.

      But yes, I 100% do share your frustration, this was WAY to hard to get working on a new laptop, fully updated.

    • itsmrwalshtoyou

      Go back home and ask your mother to teach you the manners she so clearly forgot to impart. What a childish, selfish post.

      Maybe you should fix your own problems in the future rather than complaining about other people just trying to help you.

  • z_human

    @adriel:disqus
    Hey Adrel, it did not work for me either. any other thoughts that you can think of? anything might help? Thank you for sharing!

  • Saif Younes

    you are the best man it worked perfectly for me I don’t usually respond to solutions, this is my first, I went and took an appointment with the genius bar, they didn’t know how to solve this problem, they told me to fucking back up my laptop and come back and that alone was a shit ton of time wasting, so thank you again

    • https://adriel.co.nz Adriel

      Hey Saif, Thank you for the nice feedback. Knowing that it’s at least helped one person makes writing the article worth it.

  • Sarah Amaral

    I have a brand new iMac with nothing at all on the hard drive. Tried to run bootcamp. kept getting the error message. have been working with apple care senior advisor wiping my hard drive and reinstalling high Sierra 3/4 times now. I do not, no have I ever had time machine turned on. extremely frustrating, I would love to hear if any one else has any ideas. Thank you,

    • https://adriel.co.nz Adriel

      Hey Sarah, how are you reinstalling Sierra? You tried using the internet recovery method above with formatting the whole internal disk (not just the partition). If you have, the best advise I have is to keep talking with the Apple care guys, if anyone can help, it’s them.

      If you get it working please let us know here, to help others.

  • Sarah Amaral

    Update on the advise of Apple, I ran first aid today on the hard drive the tried to partition from disk Utility and It worked. So I erased the partition and went ahead with boot camp assistant. This time it ran further but started to run really slow once it started to create the partition. It got about 3/4 of the way through then gave me the same error message. So it’s back with the engineers at Apple they seem to be completely stumped as well. So frustrating

    • https://adriel.co.nz Adriel

      Thanks for the update! Hopefully this will help the engineers work on a fix to make it more stable for all. (and better error messages)

    • Guy Williams

      Is it High sierra because I still get the issue with High sierra

  • rboyle

    The tmutil trick worked for me. Many thanks!

    • https://adriel.co.nz Adriel

      Thanks for the great feedback!