9 Replies Latest reply: Aug 15, 2012 9:54 AM by Christopher Murphy
revluvv Level 1 Level 1 (0 points)

Hi,

I need some assistance reclaiming my hard drive. When I set up my mac I foolishly thought I may need XP so I used bootcamp to set a partition of 32 gig.

I tried to reclaim it per the instructions of others ( delete partition, then pull the main "box" down to reclaim the space. It gives me an error and reverts back to the original state minus the windows drive. So I have 32gig of dead space. Any assistance would be most appreciated . running 10.5.8

 

Model Name:MacBook Pro
  Model Identifier:MacBookPro4,1
  Processor Name:Intel Core 2 Duo
  Processor Speed:2.6 GHz
  Number Of Processors:1
  Total Number Of Cores:2
  L2 Cache:6 MB
  Memory:4 GB
  Bus Speed:800 MHz
  Boot ROM Version:MBP41.00C1.B03
  SMC Version (system):1.27f3

MacBook Pro, Mac OS X (10.5.8)
  • 1. Re: bootcamp partision removal
    Christopher Murphy Level 3 Level 3 (525 points)

    Provide the results from

    sudo gpt -r -vv show disk0

    diskutil resizevolume /dev/disk0s2 limits

     

    If you get bored waiting for a reponse in the meantime, make sure you have good backups. Basically the GPT first needs to be cleared of the old Windows partition. Next there's a good chance the HFS+ catalog needs to be rebuilt before it will succesfully resize.

  • 2. Re: bootcamp partision removal
    The hatter Level 9 Level 9 (58,880 points)

    It sounds like you used Disk Utility, the instructions were to use Boot Camp Assistant again, the same way you created it to begin with.

  • 3. Re: bootcamp partision removal
    revluvv Level 1 Level 1 (0 points)

    Chris, Thanks for your response. I'm not sure what exactly I need to do. I really hoping for a utility or a procedure that I can follow to get this cleaned up. If you can direct me, that would be most appreciated.

  • 4. Re: bootcamp partision removal
    revluvv Level 1 Level 1 (0 points)

    Senor Hatter,

    I looked at that app. It will allow me to add more but not reclaim the xp space back. I did use the disk utility to "erase" the partition. Still have not come up with a good solution. any additional steps I can take would be appreciated. Thx in advance.

  • 5. Re: bootcamp partision removal
    Christopher Murphy Level 3 Level 3 (525 points)

    There is no utility/procedure other than obliterating the disk and restoring from backups, if you're more comfortable with that. Otherwise, go to Terminal and type the following commands and post the results:

     

    sudo gpt -r -vv show disk0

     

    diskutil resizevolume /dev/disk0s2 limits

  • 6. Re: bootcamp partision removal
    BobTheFisherman Level 6 Level 6 (10,970 points)

    Boot Camp Assistant is the way to remove the Boot Camp partition containing Windows and restore your hard drive to a single OSx partition. In Boot Camp Assistant there was, before you started messing with disk utility, a menu item to perform this task.

     

    Now that you have used disk utility you have created a difficult situation possibly requiring re-format of your hard drive. Follow The hatter's instructions. You will need to recover your data from your backup. If you have no backup your data is likely lost.

     

    Search this forum for similar posts and solutions.

  • 7. Re: bootcamp partision removal
    Christopher Murphy Level 3 Level 3 (525 points)

    I agree that Boot Camp Assistant should be used to remove the BOOTCAMP partition containing Windows.

     

    But it's egregious that Disk Utility allows modification of the disk in a manner that borks the partition maps to the point no provided utilities, including Boot Camp Assistant, can fix. And in fact Disk Utility's behavior violates Apple's on dev note on the issue: it should not be modifying disks with hybrid MBRs, in particular if it will result in data loss or disk space loss both of which are possible when manipulating a such a disk with Disk Utility. This is absolutely not user error.

     

    If you have no backup your data is likely lost.

     

    The data is not at risk. He has 32GB of free space that he can't reclaim for Mac OS X. This is often managable with diskutil resizevolume command, but the limits need to be determined before attempting it because inexplicably the command sometimes fails due to the presence of Recovery HD in between the Mac OS volume and Free Space. Even then, it's possible to move Recovery HD to the end of the disk and then resize the HFS+ volume. But I'm not aware of any utilities that can do this automagically once the situation is off the standard set of rails.

  • 8. Re: bootcamp partision removal
    BobTheFisherman Level 6 Level 6 (10,970 points)

    Christopher Murphy wrote:

     

    I agree that Boot Camp Assistant should be used to remove the BOOTCAMP partition containing Windows.

     

    But it's egregious that Disk Utility allows modification of the disk in a manner that borks the partition maps to the point no provided utilities, including Boot Camp Assistant, can fix. And in fact Disk Utility's behavior violates Apple's on dev note on the issue: it should not be modifying disks with hybrid MBRs, in particular if it will result in data loss or disk space loss both of which are possible when manipulating a such a disk with Disk Utility. This is absolutely not user error.

     

    If you have no backup your data is likely lost.

     

    The data is not at risk. He has 32GB of free space that he can't reclaim for Mac OS X. This is often managable with diskutil resizevolume command, but the limits need to be determined before attempting it because inexplicably the command sometimes fails due to the presence of Recovery HD in between the Mac OS volume and Free Space. Even then, it's possible to move Recovery HD to the end of the disk and then resize the HFS+ volume. But I'm not aware of any utilities that can do this automagically once the situation is off the standard set of rails.

    We are not debating the operation of Didk Utility.

     

    The original poster did not follow the procedure for removing a Boot Camp partition and is now faced with the possibly refomatting his hard drive. This will cause loss of everything on the drive.

     

    If you have an issue with how Disk Utility works you should let Apple know how "egregious" Disk Utility is. We are just users here and can do nothing about the design of Disk Utility or other Apple applications.

  • 9. Re: bootcamp partision removal
    Christopher Murphy Level 3 Level 3 (525 points)

    You're asserting the OP did something wrong by using Disk Utility instead of Boot Camp Assistant. Your logic is flawed.

     

    There is no proscription using Disk Utility in the manner the OP described, in either the Boot Camp User Guide or any knowledge base articles. The problem is clearly occuring with resizing the Mac OS volume to re-assume free space. This is a common problem, I've had it happen myself and neither Disk Utility, Boot Camp Assistant, nor 'diskutil resizevolume' (which is ultimately the resize program both DU and BCA use). In a handful of cases rebuilding the catalog file fixed the problem and enabled diskutil to resize the volume. In most cases I had to manually delete or relocate the Recovery HD partition so that the free space butted up right next to the Mac OS volume to be resized.

     

    The reality is that Boot Camp partitioning is flakey and dangerous. In my view it should be relegate to unimportant things like games, which also need the performance. Otherwise people should use Windows in a VM using virtual disks.