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 92 of 102 last Next
  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Jul 4, 2014 12:32 PM in response to Bx029297
    Level 3 (555 points)
    Jul 4, 2014 12:32 PM in response to Bx029297

    Yeah you can blow away Recovery HD to gain an extra MBR slot, but with a bit of knowledge, you can keep it and just create a non-standard hybrid MBR.

     

    Understand that things are nice in Apple land mainly because of the *lack* of options. The Linux world has a dozen boot managers/loaders, at least one of which might be argued to be a baby operating system. On Macs there is one boot manager (built into the firmware) and one bootloader (boot.efi) and essentially no user interface and no configuration files. So it's not just being off rails you have a dozen rails of different sizes and thousands of opinions about each. So narrowing down the choices is a lot of work and source of confusion.

     

    Since I use FileVault 2, I have to keep Recovery HD since it acts as the unencrypted boot volume. And so I'm reluctant to endorse deleting Recovery HD but yes it can be done and it makes it a bit simpler if you really have no need for it (it's the same as it was with Snow Leopard and older).

     

    And also I use Fedora, which has a totally unique way of supporting Linux on Macs. They don't use the Apple created EFI System partition. Instead they create a small 200MB HFS+ volume to use as an EFI System partition. This makes it possible to show Fedora as a boot menu option in System Preferences > Startup, as well as the option-key boot chime boot manager menu. I don't know any other Linux that does this.

     

    If you're going to use Ubuntu, I'm not exactly sure how they support Macs with EFI booting, or how you switch between OS X and Ubuntu and Windows. I only use Ubuntu in a VM. By default they're going to use GRUB, so initially you'll have to contend with whatever they give you out of the box. I'm going to guess you'll want to use rEFInd eventually.

  • by Bx029297,

    Bx029297 Bx029297 Jul 4, 2014 12:43 PM in response to Christopher Murphy
    Level 1 (0 points)
    Jul 4, 2014 12:43 PM in response to Christopher Murphy

    Thanks for the well detailed post,

     

    Is creating the hybrid MBR using gdisk the second option?

     

    and first option is then the one i suggested with installing windows last? I'm not sure i know exactly how to go about using gdisk for partitioning disk...

  • by Loner T,

    Loner T Loner T Jul 4, 2014 4:09 PM in response to Bx029297
    Level 7 (24,596 points)
    Safari
    Jul 4, 2014 4:09 PM in response to Bx029297

    As Christopher says, you will need to have a Hybrid MBR in either case for Windows to work. What you include in the MBR is where you have choices.

     

    But the bottom line is, if you're going to do triple booting, you're really off the rails and you need to understand what tools you can and can't use, have good backups and recovery plans, and understand how to recreate the proper hybrid MBR in case you do inadvertently use a tool you shouldn't have and it breaks booting.

  • by Bx029297,

    Bx029297 Bx029297 Jul 5, 2014 6:24 PM in response to Christopher Murphy
    Level 1 (0 points)
    Jul 5, 2014 6:24 PM in response to Christopher Murphy

    Christopher, i have now formatted my whole HDD, had a single one Mac OS x,

    After running Bootcamp i managed to create 2 more partitions:

     

    so partitions in disk utility looked like: - Mac Os X

                                                           - Linus Swap

                                                           - Ubuntu

                                                           - Bootcamp

     

    whereas after typing in command " sudo gdisk /dev/disk0"

                                                     "p"

    in order to know my partition number i had : 1 EFI System Partition

                                                                    2 Apple_HFS_Untitiled_2

                                                                    3 Recovery HD

                                                                    4 LINUX swap

                                                                    5 Ubuntu

                                                                    6 Bootcamp

     

    i then tried to install windows 7 but couldn't find out why when choosing which partition i wanted it on it said:

     

    windows cannot be installed on this disk. The selected disk is of the GPT partition style.

    Do i need to sort out the hybrid mbr first or is it a format problem?

  • by Loner T,

    Loner T Loner T Jul 5, 2014 7:33 PM in response to Bx029297
    Level 7 (24,596 points)
    Safari
    Jul 5, 2014 7:33 PM in response to Bx029297

    Bootcamp expects an MBR which you can see via fdisk. Can you post the output of sudo fdisk /dev/disk0 as it is now?

     

    How did you create Partition 6, via Bootcamp Assistant or by hand?

  • by Bx029297,

    Bx029297 Bx029297 Jul 6, 2014 4:50 AM in response to Loner T
    Level 1 (0 points)
    Jul 6, 2014 4:50 AM in response to Loner T

    The output is :

    Disk: /dev/disk0geometry: 38913/255/63 [625142448 sectors]

    Signature: 0xAA55

             Starting       Ending

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

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

    1: EE 1023 254  63 - 1023 254  63 [         1 -  625142447] <Unknown ID>

    2: 00    0   0   0 -    0   0   0 [         0 -          0] unused    

    3: 00    0   0   0 -    0   0   0 [         0 -          0] unused    

    4: 00    0   0   0 -    0   0   0 [         0 -          0] unused    

     

    And yes created the bootcamp partition with bootcamp assistant.

    Then while bootcamp was partitioning hit the eject key and to eject the windows installation DVD and quit installation

    Went to Disk Utility and created 2 more partitions LINUX SWAP and Ubuntu.

     

    Am i meant to only use gdisk now and convert partition 6 from gpt to mbr or do i need to sort out the hybrid mbr first.

     

    This is really confusing but i really need to understand..

  • by Loner T,

    Loner T Loner T Jul 6, 2014 5:27 AM in response to Bx029297
    Level 7 (24,596 points)
    Safari
    Jul 6, 2014 5:27 AM in response to Bx029297

    Bootcamp Assistant was prematurely terminated, hence the GPT side was created, but nothing on the MBR side points to it.

     

    If you run sudo gpt -vv -r show /dev/disk0 you should see appropriate entries (you may want to post them here). The Hybrid MBR needs to exist before Windows can be installed. It will need to see a FAT partition (that is converted during installation to NTFS).

     

    I would also suggest you create a separate thread (and post a reference here), this thread is no longer appropriate for this discussion.

  • by Bx029297,

    Bx029297 Bx029297 Jul 6, 2014 5:55 AM in response to Loner T
    Level 1 (0 points)
    Jul 6, 2014 5:55 AM in response to Loner T

    Thanks Loner T , reference to new thread is Issues with hybrid mbr and bootcamp partition

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Jul 6, 2014 8:18 AM in response to Bx029297
    Level 3 (555 points)
    Jul 6, 2014 8:18 AM in response to Bx029297

    Create the hybrid MBR with gdisk, adding only the Windows partition. The end result would look something like this:

     

    Command (? for help): r

     

    Recovery/transformation command (? for help): p

    Disk /dev/sdb: 167772160 sectors, 80.0 GiB

    Logical sector size: 512 bytes

    Disk identifier (GUID): 33141995-B6EE-4DC0-B43A-0FCD9BA64AA4

    Partition table holds up to 128 entries

    First usable sector is 34, last usable sector is 167772126

    Partitions will be aligned on 2048-sector boundaries

    Total free space is 2014 sectors (1007.0 KiB)

     

    Number  Start (sector)    End (sector)  Size      Code  Name

      1            2048          411647   200.0 MiB   EF00  EFI System

      2          411648        61229055   29.0 GiB    AF00  Apple HFS/HFS+

      3        61229056        62560255   650.0 MiB   AB00  Apple boot

      4        62560256        63584255   500.0 MiB   8300  Linux filesystem

      5        63584256        84555775   10.0 GiB    8E00  Linux LVM

      6        84555776       167772126   39.7 GiB    0700  Microsoft basic data

     

    Recovery/transformation command (? for help): o

     

    Disk size is 167772160 sectors (80.0 GiB)

    MBR disk identifier: 0x00000000

    MBR partitions:

     

    Number  Boot  Start Sector  End Sector  Status      Code

      1                    1    84555775    primary     0xEE

      2      *      84555776    167772126   primary     0x07

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Jul 6, 2014 8:23 AM in response to Bx029297
    Level 3 (555 points)
    Jul 6, 2014 8:23 AM in response to Bx029297

    You can't use any of Apple's GUI utilities on a disk that has more than 4 partitions. That includes Boot Camp Assistant. It will not create a hybrid MBR if the GPT contains 5 or more partitions. You have to use gdisk, or manually create the hybrid MBR using fdisk. If you're unwilling to give up GUI utilities then don't create 5+ partition disks (that's 3 visible partitions in Disk Utility, since two are hidden).

  • by Bx029297,

    Bx029297 Bx029297 Jul 6, 2014 8:34 AM in response to Christopher Murphy
    Level 1 (0 points)
    Jul 6, 2014 8:34 AM in response to Christopher Murphy

    ok Chris please tell me if i'm missing something

     

    Option 1From my single partition Mac OS x should i first use bootcamp assistant to create my bootcamp partition

    then create my linux swap and ubuntu partitions

    then use gdisk to create the hybrid mbr?

     

    or not use bootcamp assistant at all and first create partitions with gdisk then the hybrid mbr?

     

    by the way let's say in gdisk partition number ; 1 EFI System Partition

                                                                    2 Apple_HFS_Untitiled_2

                                                                    3 Recovery HD

                                                                    4 LINUX swap

                                                                    5 Ubuntu

                                                                    6 Bootcamp

     

    when they ask

     

    "Type from one to three GPT partition numbers, separated by spaces, to be

    added to the hybrid MBR, in sequence: " which numbers would suit in order to create the hybrid MBR that you just showed me?

     

    thank you

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Jul 6, 2014 10:23 AM in response to Bx029297
    Level 3 (555 points)
    Jul 6, 2014 10:23 AM in response to Bx029297

    should i first use bootcamp assistant to create my bootcamp partition then create my linux swap and ubuntu partitions then use gdisk to create the hybrid mbr?


    No. Because Boot Camp Assistant will only make GPT and MBR partition #4 for Windows, and that's not what you want. You want Linux in between OS X and Windows last, and Boot Camp Assistant cannot do that for you.


    Also the proscription on GUI applications extends to the installer when doing major OS X upgrades. It runs diskutil repairdisk which right now always removes hybrid MBRs if the GPT contains 5 or more partitions. So anytime you do a major OS X upgrade in this configuration, the hybrid MBR will be removed and Windows will be unbootable until you recreate the hybrid MBR. So you need to be comfortable with recreating hybrid MBRs with gdisk. Boot Camp Assistant cannot help you at all with the configuration you want.

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Jul 6, 2014 10:25 AM in response to Bx029297
    Level 3 (555 points)
    Jul 6, 2014 10:25 AM in response to Bx029297

    OK you're bouncing back and forth between two threads. Let's both stop responding to this thread and focus on the other one you created since that one is specifically about triple booting.

  • by NikkuShouri,

    NikkuShouri NikkuShouri Jul 10, 2014 1:14 PM in response to Christopher Murphy
    Level 1 (0 points)
    Jul 10, 2014 1:14 PM in response to Christopher Murphy

    I could really use some help if you don't mind Christopher. You seem very knowledgeable in this area.

     

    My problem is that I cannot get windows to boot after swapping my hard drives to a new machine. I had a 2010 MacBook Pro 15" with a 512 gb SSD with only OSX and a 750 gb HDD with a 250 gb partition for Windows and a 500 gb partition for storage(Formatted with Mac OS Extended) installed in the superdrive slot. Everything was working fine in the 2010 model but when I moved it over to the 2012 MacBook Pro 15" it will not boot. I have had a few different errors such as "Operating System not found" and the most recent is "No Bootable Device Found." I have also tried making a repair disk and tried using it multiple times with different errors each time. Now when I boot to that it just says "This version of System Recovery is not compatible with the version of Windows you are trying to repair" even though its the same bootable usb I used other times and it loaded fine.

     

    The kicker is that it loads just fine in Parallels and all my files are visible from OSX but it will not boot natively to Windows. Which is what I need to be able to use the full power of the graphics card. I will also note that I used the instructions here http://twocanoes.com/support/winclone/migrating-a-bootcamp-partition-with-winclo ne so that I could install the bootcamp drivers for the 2012 model.

     

    Any and all help would be greatly appreciated.

     

    Oh and maybe this will help too:

    nicholas-macbook-pro:~ nicholas$ diskutil list

    /dev/disk0

       #:                       TYPE NAME                    SIZE       IDENTIFIER

       0:      GUID_partition_scheme                        *512.1 GB   disk0

       1:                        EFI EFI                     209.7 MB   disk0s1

       2:                  Apple_HFS Macintosh SSD           511.3 GB   disk0s2

       3:                 Apple_Boot Recovery HD             650.0 MB   disk0s3

    /dev/disk1

       #:                       TYPE NAME                    SIZE       IDENTIFIER

       0:      GUID_partition_scheme                        *750.2 GB   disk1

       1:                        EFI EFI                     209.7 MB   disk1s1

       2:                  Apple_HFS Storage                 450.0 GB   disk1s2

       3:                  Apple_HFS 10.10 Test              49.9 GB    disk1s3

       4:       Microsoft Basic Data BOOTCAMP                249.8 GB   disk1s4

    /dev/disk2

       #:                       TYPE NAME                    SIZE       IDENTIFIER

       0:     FDisk_partition_scheme                        *16.2 GB    disk2

       1:             Windows_FAT_32 NO NAME                 16.2 GB    disk2s1

     

    nicholas-macbook-pro:~ nicholas$ sudo gdisk /dev/disk1

    Password:

    GPT fdisk (gdisk) version 0.8.10

     

    Warning: Devices opened with shared lock will not have their

    partition table automatically reloaded!

    Partition table scan:

      MBR: hybrid

      BSD: not present

      APM: not present

      GPT: present

     

    Found valid GPT with hybrid MBR; using GPT.

  • by Loner T,

    Loner T Loner T Jul 10, 2014 1:34 PM in response to NikkuShouri
    Level 7 (24,596 points)
    Safari
    Jul 10, 2014 1:34 PM in response to NikkuShouri

    Please start a new thread and post a reference to it here.

     

    Can you post the complete output of the gdisk  (use the 'p' option) ? Can you also post the output of sudo fdisk /dev/disk1 and  sudo gpt -vv -r show /dev/disk1?

     

    You also have 10.10 Test on the same disk.

first Previous Page 92 of 102 last Next