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

    Christopher Murphy Christopher Murphy Nov 26, 2013 7:59 PM in response to zvav
    Level 3 (555 points)
    Nov 26, 2013 7:59 PM in response to zvav

    Ok so 7 partitions isn't supported by Apple for Bootcamped systems. The max is four because MBR's only support four primary partitions. So there isn't a correct way to fix this that's going to be permanent, it'll always be fragile. Assuming you don't need to access the OS X volume from Ubuntu, you can create a new hybrid MBR with gdisk, adding partitions 5 6 7. It doesn't matter which one is made bootable, because GRUB doesn't depend on the active bit being set, but Apple's firmware does, to active the CSM-BIOS. So just pick one, and only one, to set the boot flag on.

     

    Down the road you'll want to see if a newer version of Ubuntu, or a differnt distribution (like Fedora which has explicitly supported Mac EFI booting with Startup Disk support for ~ 2 years), so that you can EFI boot linux. This eliminates the need for MBR, and removes the 4 partition limitation, no need for Bootcamping, and also doesn't use the CSM-BIOS to boot.

  • by saarhotboy,

    saarhotboy saarhotboy Nov 28, 2013 5:24 AM in response to Scotch_Brawth
    Level 1 (0 points)
    Nov 28, 2013 5:24 AM in response to Scotch_Brawth

    Hi dear Christopher Murphy

     

    First thank you so much for solving problems of tons of users here.

     

    I have the same problem in booting my win 7 after creating a new partition.

    I did the things that you said in page 1 to make a hybrid MBR but the problem is not solved. Right after making the hybrid mbr and rebooting my mac, I couldn't still see windows partition to boot and there were only two partitions to boot: "Mac os X" and "Recovery hd".

    After some try to fix the problem by booting win 7 dvd and use its fix startup option, now when I turn on my macbook pro, I see 3 partitions to boot: "Mac os x", "Windows" and "Recovery HD".

    I can boot mac os x but when I choose "Windows", a black screen appears and nothing happend more.(A tiny question here, how can I restart my mac in this situation? I have to turn it off by pushing power button for 5 sec and turn it on again!)

    And the win 7 dvd startup repair says there is no problem!

    This is the result of gpt:

    amirabass-MacBook:~ amirabbas$ sudo gpt -r -vv show disk0

    Password:

    gpt show: disk0: mediasize=500107862016; sectorsize=512; blocks=976773168

    gpt show: disk0: Suspicious MBR at sector 0

    gpt show: disk0: Pri GPT at sector 1

    gpt show: disk0: Sec GPT at sector 976773167

          start       size  index  contents

              0          1         MBR

              1          1         Pri GPT header

              2         32         Pri GPT table

             34          6        

             40     409600      1  GPT part - C12A7328-F81F-11D2-BA4B-00A0C93EC93B

         409640  332031248      2  GPT part - 48465300-0000-11AA-AA11-00306543ECAC

      332440888    1269536      3  GPT part - 426F6F74-0000-11AA-AA11-00306543ECAC

      333710424        936        

      333711360  307517440      4  GPT part - EBD0A0A2-B9E5-4433-87C0-68B6B72699C7

      641228800  335544320      5  GPT part - EBD0A0A2-B9E5-4433-87C0-68B6B72699C7

      976773120         15        

      976773135         32         Sec GPT table

      976773167          1         Sec GPT header

    And this is for fdisk:

     

    amirabass-MacBook:~ amirabbas$ sudo fdisk /dev/disk0

    Disk: /dev/disk0    geometry: 60801/255/63 [976773168 sectors]

    Signature: 0xAA55

             Starting       Ending

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

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

    1: EE    0   0   2 - 1023 254  63 [         1 -  641228799] <Unknown ID>

    *2: 07 1023 254  63 - 1023 254  63 [ 641228800 -  335544320] HPFS/QNX/AUX

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

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

     

    and this is for diskutil:

     

    amirabass-MacBook:~ amirabbas$ sudo diskutil list

    Password:

    /dev/disk0

       #:                       TYPE NAME                    SIZE       IDENTIFIER

       0:      GUID_partition_scheme                        *500.1 GB   disk0

       1:                        EFI                         209.7 MB   disk0s1

       2:                  Apple_HFS Macintosh HD            170.0 GB   disk0s2

       3:                 Apple_Boot Recovery HD             650.0 MB   disk0s3

       4:       Microsoft Basic Data DATA                    157.4 GB   disk0s4

       5:       Microsoft Basic Data BOOTCAMP                171.8 GB   disk0s5

    /dev/disk1

       #:                       TYPE NAME                    SIZE       IDENTIFIER

       0:                            W7_SP1_All_SKU_x86-... *4.3 GB     disk1

     

     

    Please answer me asap cuz I need my win for uni. works and I dont want start from scratch.

     

    PS: I had my mac os x and my win. my win partition was too small. I resized my mac partition in mac os x and left a huge free space. I went to win 7 and by a partition manager program(acronis), I resized my win partition to be bigger and also I made a new partition, and when it restarted the laptop the problem appeared!

  • by Loner T,

    Loner T Loner T Nov 28, 2013 7:31 AM in response to saarhotboy
    Level 7 (24,202 points)
    Safari
    Nov 28, 2013 7:31 AM in response to saarhotboy

    Please start with taibanl'spost on page 59. You may end up using Testdisk (http://www.cgsecurity.org/wiki/TestDisk_Download). Also, Christopher has posted this earlier, if you are interested (http://www.rodsbooks.com/gdisk/hybrid.html).


     


  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Nov 28, 2013 8:32 AM in response to saarhotboy
    Level 3 (555 points)
    Nov 28, 2013 8:32 AM in response to saarhotboy

    Since you don't say what you did, I'm guessing you resized the Windows volume while booted in Windows in order to get this layout. There are 5 partitions:

    ESP=200MB

    OS X=158GB

    Recovery HD=650MB

    Windows=150GB

    Windows=164GB

     

    Try recreating the hybrid MBR, adding partition 4, and making it bootable. There's no correct way to make a hybrid MBR for this that protects everything. If you want to be able to use the OS X volume in Windows, as well as the 2nd "Windows" volume, then you need to create a hybrid MBR with partitions 2 4 5, making 4 bootable. This will expose the Recovery HD partition, and it will appear as unallocated free space in Windows, but that's pretty much the safest option.

  • by saarhotboy,

    saarhotboy saarhotboy Nov 28, 2013 8:52 AM in response to Scotch_Brawth
    Level 1 (0 points)
    Nov 28, 2013 8:52 AM in response to Scotch_Brawth

    Thank you christopher for your answer.

     

    What do you exactly want me to say about what I did? (Did you read the PS in my post?)

     

    In this 5 partition mode, I know that the last partition(windows) is my win 7 partition and the forth is a free partition that I have made in mac os x by utility disk and formatted it as ex-Fat. I can delete this partition or reformat it if it helps the problem to be solved.

     

    Yes, I resized my windows partition in windows by a third party program called Acronis. Now I can see windows partition when turn on my mac but when I choose it a black screen apears and only a dash  blanking.

    (I read the pages but 48 onward to 52 but couldnt figure out the solution!)

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Nov 28, 2013 9:02 AM in response to saarhotboy
    Level 3 (555 points)
    Nov 28, 2013 9:02 AM in response to saarhotboy

    Yeah so you're going to need to use test disk to find the true start of the Windows volume. And because you've done so much resizing and you created a 2nd Windows volume, it might be difficult to find the true end of that first Windows volume. So skip the hybrid MBR stuff until you've gone through this with test disk. I think most of the relevant stuff is after page 52. The key thing is that you must get to the point where you can "list files" and actually see your stuff. Other partition sector start and sector end values that don't let you list files are the wrong start and end values. Only the exact correct start-end values will define the partition for your Windows volume and data.

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Nov 28, 2013 9:06 AM in response to saarhotboy
    Level 3 (555 points)
    Nov 28, 2013 9:06 AM in response to saarhotboy

    The gist is that Acronis didn't update the GPT. So the GPT contains all incorrect and useless information. The MBR did have correct information from Acronis, but then OS X decided to "fix" it by removing the hybrid MBR. So the partition information for your Windows volumes is lost. Testdisk will help find the start-end sector values for each of those partitions, but it might take a while, especially if it finds many (stale) candidates from all of the changes you've made.

     

    Once you get the correct information from testdisk, you'll use gdisk to make the changes to the GPT by removing the two bogus Windows partitions, adding the proper new ones based on successful "list files" results from testdisk, and only then will you create a hybrid MBR and save all of this out to disk.

  • by saarhotboy,

    saarhotboy saarhotboy Nov 28, 2013 9:41 AM in response to Scotch_Brawth
    Level 1 (0 points)
    Nov 28, 2013 9:41 AM in response to Scotch_Brawth

    Are you sure that my problem is because of the start of my windows partition is not correctly defined?

    Because its size was 90 GB and now in mac os, utility disk and every where else is cOrrectly

    150 Gb.

    And also I can see my windows partition and all of its contents correctly in finder.

    By the way, if I found a new start for my partiton ho w can i fix it?

  • by Christopher Murphy,

    Christopher Murphy Christopher Murphy Nov 28, 2013 10:02 AM in response to saarhotboy
    Level 3 (555 points)
    Nov 28, 2013 10:02 AM in response to saarhotboy

    Well it's possible Acronis has actually changed the GPT, but historically that wasn't the case if it was launched in Windows that's booted in BIOS mode. Windows booted BIOS mode only honors MBRs, and totally ignores GPTs on the boot disk.

     

    The fact you can see your files in the OS X Finder sounds like you should just be able to recreate the hybrid MBR with partition 4 bootable and you'll be able to boot Windows. Currently you have partition 5 set to boot Windows which is probably the extra NTFS volume you created.

  • by saarhotboy,

    saarhotboy saarhotboy Nov 28, 2013 12:32 PM in response to Scotch_Brawth
    Level 1 (0 points)
    Nov 28, 2013 12:32 PM in response to Scotch_Brawth

    However I was sure that the partition 5 contains my win 7 and partition 4 is free, I did what you said. When I restarted my mac and chose windows, a black screen apeard with "No system disk, Press any key to reboot" .

     

    I am really exhausted of this problem, please give me a help to solve it. Please ask me a question if you think you are not completly sure about the situation and the problem,\.

    thanks

  • by Loner T,

    Loner T Loner T Nov 28, 2013 1:07 PM in response to saarhotboy
    Level 7 (24,202 points)
    Safari
    Nov 28, 2013 1:07 PM in response to saarhotboy

    saarhotboy wrote:

    After some try to fix the problem by booting win 7 dvd and use its fix startup option, now when I turn on my macbook pro

     

    saarhotboy wrote:

    However I was sure that the partition 5 contains my win 7 and partition 4 is free, I did what you said. When I restarted my mac and chose windows, a black screen apeard with "No system disk, Press any key to reboot"

     

    This is confusing. You did try a Windows repair, when BOTH volumes were present. Do you see your system files in OS X when your Bootcamp partition is mounted?

     

  • by saarhotboy,

    saarhotboy saarhotboy Nov 28, 2013 1:08 PM in response to Scotch_Brawth
    Level 1 (0 points)
    Nov 28, 2013 1:08 PM in response to Scotch_Brawth

    I am gonna start everything from scratch!

    If anyone can help me, please stop me before doing that and save me a lot time!

     

    Let me describe my problem again.

    I can see my windows partition in finder, I can see all of stuff in it and copy them to my mac partition.

    I can see my windows partition in the startup options when I turn on my mac(after making a hybrid mbr by gdisk) but when I choose it, a black screen with a blanking dash appears.

    I have resized my mac partition in mac os x and my windows partition in windows by Acronis, but now in man in disk utility, all of driver sizes are correct and logocal.

    please help me not start from scratch!

  • by saarhotboy,

    saarhotboy saarhotboy Nov 28, 2013 1:11 PM in response to Loner T
    Level 1 (0 points)
    Nov 28, 2013 1:11 PM in response to Loner T

    I did a windows repair when both volums were present because however it was present, but when I chose windows to boot, just a black screen appeard and nothing more.

     

    Yes, I see my system files and all of my files in windows partition called bootcamp in the finder in mac os x.

  • by Loner T,

    Loner T Loner T Nov 28, 2013 1:14 PM in response to saarhotboy
    Level 7 (24,202 points)
    Safari
    Nov 28, 2013 1:14 PM in response to saarhotboy

    Before you start from scratch, please take a look at this...

     

    https://discussions.apple.com/thread/2746125

     

    See Simon's post.

  • by saarhotboy,

    saarhotboy saarhotboy Nov 28, 2013 1:30 PM in response to Loner T
    Level 1 (0 points)
    Nov 28, 2013 1:30 PM in response to Loner T

    thanks for the thread but didn't help! I mean didn't solve the problem

first Previous Page 61 of 102 last Next