Scotch_Brawth

Q: Repairing Boot Camp after creating new partition

I'm running OS X 10.8 and Windows 7 x64 Pro.

 

After properly setting up Boot Camp to dual-boot Windows on my Mac mini, I decided to test whether or not it was true that creating another partition (a data partition for OS X) would interfere with Boot Camp.  Wikipedia claims it does interfere but without citing a source, whilst the Boot Camp documentation itself only specifies that the disk must be a single partition _prior_ to setup - there's no mention of whether the disk must be _kept_ that way afterwards.

 

I opened Disk Utility, reduced the size of my OS X parition from 420GB to 80GB, and created a new partition in the unallocated space.  Here's how it looks now:

/___sbsstatic___/migration-images/190/19047693-1.png

When I attempted to proceed with the process, I did receive a warning that doing this (and I quote), "may" cause problems with Boot Camp.  Seeing as it was inconclusive, I thought I'd give it a shot - nothing ventured…

 

Of course, it borked Boot Camp, otherwise I wouldn't be posting here.  Whilst OS X boots just fine, the Boot Camp partition now no longer shows up in the Startup Manager, though it does in the Startup Disk prefPane.  If I do attempt to boot into Boot Camp, I receive the following message on a black screen:

No bootable device --- insert boot disk and press any key

The advice given to someone who had this same problem was, "fix your damaged Boot Camp volume."  But I'm at a loss as to how to do that.

 

So, anyone know how to proceed now so that I can keep my partitions as is, whilst fully restoring normal Boot Camp functionality?

Mac mini (Mid 2011), Mac OS X (10.7.4)

Posted on Jul 26, 2012 11:28 PM

Close

Q: Repairing Boot Camp after creating new partition

  • All replies
  • Helpful answers

first Previous Page 40 of 102 last Next
  • by berkeley201,

    berkeley201 berkeley201 Mar 14, 2013 1:49 PM in response to Christopher Murphy
    Level 1 (0 points)
    Mar 14, 2013 1:49 PM in response to Christopher Murphy

    WOW - that worked! I had to use the fix suggested on the page you linked to:

     

    • bcdedit /export C:\BCD_Backup
    • c:
    • cd boot
    • attrib bcd -s -h -r
    • ren c:\boot\bcd bcd.old
    • bootrec /RebuildBcd

     

    And that worked. So now I booted into my Win7 partition and everything there was fine!

     

    So that solved the main issue for me. Thanks a million!!!

     

    If I can recover the space of the lost partition, that would be nice, but if not I can live with that


  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Mar 14, 2013 1:57 PM in response to berkeley201
    Level 3 (555 points)
    Mar 14, 2013 1:57 PM in response to berkeley201

    File system issues with the primary OS X volume need to be fixed first. Then you can try the resize command again and see if maximum is larger than current. If not, you can try to do a merge and maybe it'll ignore Recovery HD, but just in case it doesn't you'll want to back it up. CCC can do this, Recovery Disk Assistant can do it, and it can also be moved in place with dd (in which case the resize will succeed since nothing will be between the OS X volume and free space anymore).

  • by berkeley201,

    berkeley201 berkeley201 Mar 14, 2013 2:10 PM in response to Christopher Murphy
    Level 1 (0 points)
    Mar 14, 2013 2:10 PM in response to Christopher Murphy

    Disk utility does not allow resizing. It reports:

     

    Name : APPLE SSD SM256E Media
    Type : Disk

     

    Partition Map Scheme : GUID Partition Table
    Disk Identifier : disk0
    Media Name : APPLE SSD SM256E Media
    Media Type : Generic
    Connection Bus : SATA
    Device Tree : IODeviceTree:/PCI0@0/SATA@1F,2/PRT0@0/PMP@0
    Writable : Yes
    Ejectable : No
    Location : Internal
    Solid State Disk : Yes
    Total Capacity : 251 GB (251 000 193 024 Bytes)
    Disk Number : 0
    Partition Number : 0
    S.M.A.R.T. Status : Verified
    Raw Read Error : 000000000000
    Reallocated Sector Count : 000000000000
    Power On Hours : 00000000007B
    Power Cycle : 000000000E8C
    Temperature : 0040000D001D
    UDMA CRC Error (PATA only) : 000000000000

     

    sudo fdisk reports:

     

    geometry: 30515/255/63 [490234752 sectors]

    Signature: 0xAA55

         Starting   Ending
    #: id  cyl  hd sec -  cyl  hd sec [ start -   size]

    ------------------------------------------------------------------------

    1: EE 1023 254  63 - 1023 254  63 [     1 - 409639] <Unknown ID>
    2: AF 1023 254  63 - 1023 254  63 [409640 -  269273912] HFS+   
    3: AF 1023 254  63 - 1023 254  63 [ 269945696 -1269536] HFS+   

    *4: 07 1023 254  63 - 1023 254  63 [ 300509184 -  189724672] HPFS/QNX/AUX

     

    gdisk gives this partition table:

     

    Number  Start (sector)End (sector)  Size   Code  Name
       1          40      409639   200.0 MiB   EF00  EFI system partition
       2      409640   269683551   128.4 GiB   AF00  Customer
       3   269945696   271215231   619.9 MiB   AF00  Recovery HD
       4   300509184   490233855   90.5 GiB0700  BOOTCAMP
  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Mar 14, 2013 2:17 PM in response to berkeley201
    Level 3 (555 points)
    Mar 14, 2013 2:17 PM in response to berkeley201

    Did you fix the file system problems? If you didn't, you're not following directions, and jumping ahead. The only resize command I've given isn't in Disk Utility. It's this command:

     

    diskutil resizevolume /dev/disk0s2 limits

  • by berkeley201,

    berkeley201 berkeley201 Mar 14, 2013 2:23 PM in response to Christopher Murphy
    Level 1 (0 points)
    Mar 14, 2013 2:23 PM in response to Christopher Murphy

    Sorry. I didn't quite get that. I'm not very skilled at this.

     

    Diskutil resize reports:

     

            Current size:  137.9 GB (137868242944 Bytes)

            Minimum size:  64.2 GB (64220237824 Bytes)

            Maximum size:  137.9 GB (137868242944 Bytes)

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Mar 14, 2013 2:25 PM in response to berkeley201
    Level 3 (555 points)
    Mar 14, 2013 2:25 PM in response to berkeley201

    Did you fix the file system problems? Nothing else can be done until that's done.

  • by berkeley201,

    berkeley201 berkeley201 Mar 14, 2013 2:29 PM in response to Christopher Murphy
    Level 1 (0 points)
    Mar 14, 2013 2:29 PM in response to Christopher Murphy

    Again I am not quite sure what you mean, so this time I ask. Do you mean:

     

    "Make sure you have a backup of Macintosh HD first. Also I personally would reboot single user mode and:

     

    fsck_hfs -fy /dev/rdisk0s2

    fsck_hfs -r /dev/rdisk0s2

     

    The first does a normal check and repair. The 2nd rebuilds the catalog btree.

     

    Next issue this command, which reports resizing options, makes no changes.

     

    diskutil resizevolume /dev/disk0s2 limits "

     

    Keep in mind the Bootcamp issues have been fixed.

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Mar 14, 2013 2:36 PM in response to berkeley201
    Level 3 (555 points)
    Mar 14, 2013 2:36 PM in response to berkeley201

    Yes. Boot single user mode and run:

    fsck_hfs -r /dev/rdisk0s2

     

    If you continue to get errors, that volume will need to be reformatted and restored from backup. Resizing volumes with file system errors only makes things worse.

  • by berkeley201,

    berkeley201 berkeley201 Mar 14, 2013 3:02 PM in response to Christopher Murphy
    Level 1 (0 points)
    Mar 14, 2013 3:02 PM in response to Christopher Murphy

    Running it now and still getting errors. Does it matter that this is a SSD?

  • by berkeley201,

    berkeley201 berkeley201 Mar 14, 2013 3:04 PM in response to berkeley201
    Level 1 (0 points)
    Mar 14, 2013 3:04 PM in response to berkeley201

    After I type "exit" in Single user mode, it actually says "root-device is mounted read only"?!?!

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Mar 14, 2013 3:17 PM in response to berkeley201
    Level 3 (555 points)
    Mar 14, 2013 3:17 PM in response to berkeley201

    It does not matter if it's an SSD. Don't type exit, type reboot, or if that doesn't work for some reason 'shutdown -r now'.

  • by berkeley201,

    berkeley201 berkeley201 Mar 14, 2013 4:19 PM in response to Christopher Murphy
    Level 1 (0 points)
    Mar 14, 2013 4:19 PM in response to Christopher Murphy

    Neither 'reboot' nor 'shutdown' are recognized as commands.

  • by berkeley201,

    berkeley201 berkeley201 Mar 14, 2013 4:24 PM in response to Christopher Murphy
    Level 1 (0 points)
    Mar 14, 2013 4:24 PM in response to Christopher Murphy

    Before I run the

     

    fsck_hfs -r /dev/rdisk0s2

     

    when I get into the single user, it says

     

    'Singleuser boot -- fsck not done

    Root device is mounted read-only

    If you want modifications to files:

      /sbin/fsck -fy

    /sbin/mount -uw /

    If you wish to boot the system:

    exit '

     


  • by berkeley201,

    berkeley201 berkeley201 Mar 14, 2013 4:26 PM in response to Christopher Murphy
    Level 1 (0 points)
    Mar 14, 2013 4:26 PM in response to Christopher Murphy

    Seems I am running GNU bash version 3.2.48 if that helps

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Mar 14, 2013 4:34 PM in response to berkeley201
    Level 3 (555 points)
    Mar 14, 2013 4:34 PM in response to berkeley201

    I don't know what to tell you. reboot and shutdown have been around on OS X since day 1, and on BSD well before then. So if you're getting unrecognized command messages with either of those in single user mode, something isn't right with the system.

first Previous Page 40 of 102 last Next