1 21 22 23 24 25 Previous Next 1,374 Replies Latest reply: Jul 10, 2014 1:49 PM by NikkuShouri Go to original post
  • 330. Re: Repairing Boot Camp after creating new partition
    Alex Senkevich Level 1 Level 1 (0 points)

    Hello Christopher, i tried to make my windows partition live but without any results. Different VMs even usb CD-ROM.
    So i moved Windows partition to Mac OS hard disk to be able to connect Internal CD-ROM and recreate Windows MBR. So i need repeat procedure of hybrid MBR. Please help me to understand what is wrong now.

    I would like to understand for not to bother you in future.

    Thank you.

    ===================================================

    sh-3.2# diskutil list

    /dev/disk0

       #:                       TYPE NAME                    SIZE       IDENTIFIER

       0:      GUID_partition_scheme                        *256.1 GB   disk0

       1:                        EFI                         209.7 MB   disk0s1

       2:                  Apple_HFS Users                   255.7 GB   disk0s2

    /dev/disk1

       #:                       TYPE NAME                    SIZE       IDENTIFIER

       0:      GUID_partition_scheme                        *240.1 GB   disk1

       1:                        EFI                         209.7 MB   disk1s1

       2:                  Apple_HFS Mac OS                  179.0 GB   disk1s2

       3:                 Apple_Boot Recovery HD             650.0 MB   disk1s3

       4:       Microsoft Basic Data Windows 7               60.1 GB    disk1s4

    ===================================================

    sh-3.2# gpt -r -vv show disk0

    gpt show: disk0: mediasize=256060514304; sectorsize=512; blocks=500118192

    gpt show: disk0: PMBR at sector 0

    gpt show: disk0: Pri GPT at sector 1

    gpt show: disk0: Sec GPT at sector 500118191

          start       size  index  contents

              0          1         PMBR

              1          1         Pri GPT header

              2         32         Pri GPT table

             34          6        

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

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

      499856008     262151        

      500118159         32         Sec GPT table

      500118191          1         Sec GPT header

    ===================================================

    sh-3.2# fdisk /dev/disk0

    Disk: /dev/disk0    geometry: 31130/255/63 [500118192 sectors]

    Signature: 0xAA55

             Starting       Ending

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

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

    1: EE 1023 254  63 - 1023 254  63 [         1 -  500118191] <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     

    ===================================================

    sh-3.2# gpt -r -vv show disk1

    gpt show: disk1: mediasize=240057409536; sectorsize=512; blocks=468862128

    gpt show: disk1: Suspicious MBR at sector 0

    gpt show: disk1: Pri GPT at sector 1

    gpt show: disk1: Sec GPT at sector 468862127

          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  349609376      2  GPT part - 48465300-0000-11AA-AA11-00306543ECAC

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

      351288552        792        

      351289344  117448704      4  GPT part - EBD0A0A2-B9E5-4433-87C0-68B6B72699C7

      468738048     124047        

      468862095         32         Sec GPT table

      468862127          1         Sec GPT header

    ===================================================

    sh-3.2# fdisk /dev/disk1

    Disk: /dev/disk1    geometry: 29185/255/63 [468862128 sectors]

    Signature: 0xAA55

             Starting       Ending

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

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

    1: EE    0   0   2 -   25 127  14 [         1 -     409639] <Unknown ID>

    2: AF   25 127  15 - 1023 254  63 [    409640 -  349609376] HFS+       

    *3: AB 1023 254  63 - 1023 254  63 [ 350019016 -    1269536] Darwin Boot

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

    ===================================================

    sh-3.2# dd if=/dev/disk0 count=1 2>/dev/null | hexdump -C

    00000000  fa 31 c0 8e d8 8e c0 8e  d0 bc 00 7c fb fc 89 e6  |.1.........|....|

    00000010  bf 00 06 b9 00 01 f3 a5  ea 1d 06 00 00 88 16 00  |................|

    00000020  08 b4 08 cd 13 31 c0 88  f0 40 a3 f0 06 80 e1 3f  |.....1...@.....?|

    00000030  88 0e f2 06 be be 07 31  c0 b9 04 00 f6 04 80 74  |.......1.......t|

    00000040  03 40 89 f7 83 c6 10 e2  f3 83 f8 01 75 73 8a 16  |.@..........us..|

    00000050  00 08 b8 00 41 bb aa 55  31 c9 30 f6 f9 cd 13 72  |....A..U1.0....r|

    00000060  23 81 fb 55 aa 75 1d f6  c1 01 74 18 57 be e0 06  |#..U.u....t.W...|

    00000070  8b 5d 08 89 5c 08 8b 5d  0a 89 5c 0a 8a 16 00 08  |.]..\..]..\.....|

    00000080  b4 42 eb 2a 57 8b 45 08  8b 55 0a f7 36 f2 06 42  |.B.*W.E..U..6..B|

    00000090  89 d1 31 d2 f7 36 f0 06  88 c5 d1 e8 d1 e8 24 c0  |..1..6........$.|

    000000a0  08 c1 88 d6 8a 16 00 08  bb 00 7c b8 01 02 cd 13  |..........|.....|

    000000b0  72 16 5e 81 3e fe 7d 55  aa 75 08 fa ea 00 7c 00  |r.^.>.}U.u....|.|

    000000c0  00 77 05 be f4 06 eb 03  be 0f 07 ac 20 c0 74 0c  |.w.......... .t.|

    000000d0  b4 0e 8a 3e 62 04 b3 07  cd 10 eb ef eb fe 00 00  |...>b...........|

    000000e0  10 00 01 00 00 7c 00 00  00 00 00 00 00 00 00 00  |.....|..........|

    000000f0  00 00 00 00 4d 69 73 73  69 6e 67 20 6f 70 65 72  |....Missing oper|

    00000100  61 74 69 6e 67 20 73 79  73 74 65 6d 0d 0a 00 4f  |ating system...O|

    00000110  70 65 72 61 74 69 6e 67  20 73 79 73 74 65 6d 20  |perating system |

    00000120  6c 6f 61 64 69 6e 67 20  65 72 72 6f 72 0d 0a 00  |loading error...|

    00000130  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|

    *

    000001b0  00 00 00 00 00 00 00 00  11 a9 fe 7d 00 00 00 fe  |...........}....|

    000001c0  ff ff ee fe ff ff 01 00  00 00 af 32 cf 1d 00 00  |...........2....|

    000001d0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|

    *

    000001f0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 55 aa  |..............U.|

    00000200

    ===================================================

    sh-3.2# dd if=/dev/disk1 count=1 2>/dev/null | hexdump -C

    00000000  fa 31 c0 8e d8 8e c0 8e  d0 bc 00 7c fb fc 89 e6  |.1.........|....|

    00000010  bf 00 06 b9 00 01 f3 a5  ea 1d 06 00 00 88 16 00  |................|

    00000020  08 b4 08 cd 13 31 c0 88  f0 40 a3 f0 06 80 e1 3f  |.....1...@.....?|

    00000030  88 0e f2 06 be be 07 31  c0 b9 04 00 f6 04 80 74  |.......1.......t|

    00000040  03 40 89 f7 83 c6 10 e2  f3 83 f8 01 75 73 8a 16  |.@..........us..|

    00000050  00 08 b8 00 41 bb aa 55  31 c9 30 f6 f9 cd 13 72  |....A..U1.0....r|

    00000060  23 81 fb 55 aa 75 1d f6  c1 01 74 18 57 be e0 06  |#..U.u....t.W...|

    00000070  8b 5d 08 89 5c 08 8b 5d  0a 89 5c 0a 8a 16 00 08  |.]..\..]..\.....|

    00000080  b4 42 eb 2a 57 8b 45 08  8b 55 0a f7 36 f2 06 42  |.B.*W.E..U..6..B|

    00000090  89 d1 31 d2 f7 36 f0 06  88 c5 d1 e8 d1 e8 24 c0  |..1..6........$.|

    000000a0  08 c1 88 d6 8a 16 00 08  bb 00 7c b8 01 02 cd 13  |..........|.....|

    000000b0  72 16 5e 81 3e fe 7d 55  aa 75 08 fa ea 00 7c 00  |r.^.>.}U.u....|.|

    000000c0  00 77 05 be f4 06 eb 03  be 0f 07 ac 20 c0 74 0c  |.w.......... .t.|

    000000d0  b4 0e 8a 3e 62 04 b3 07  cd 10 eb ef eb fe 00 00  |...>b...........|

    000000e0  10 00 01 00 00 7c 00 00  00 00 00 00 00 00 00 00  |.....|..........|

    000000f0  00 00 00 00 4d 69 73 73  69 6e 67 20 6f 70 65 72  |....Missing oper|

    00000100  61 74 69 6e 67 20 73 79  73 74 65 6d 0d 0a 00 4f  |ating system...O|

    00000110  70 65 72 61 74 69 6e 67  20 73 79 73 74 65 6d 20  |perating system |

    00000120  6c 6f 61 64 69 6e 67 20  65 72 72 6f 72 0d 0a 00  |loading error...|

    00000130  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|

    *

    000001b0  00 00 00 00 00 00 00 00  13 a9 fe 7d 00 00 00 00  |...........}....|

    000001c0  02 00 ee 7f 0e 19 01 00  00 00 27 40 06 00 00 7f  |..........'@....|

    000001d0  0f 19 af fe ff ff 28 40  06 00 a0 9d d6 14 80 fe  |......(@........|

    000001e0  ff ff ab fe ff ff c8 dd  dc 14 20 5f 13 00 00 00  |.......... _....|

    000001f0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 55 aa  |..............U.|

    00000200

    sh-3.2#

  • 331. Re: Repairing Boot Camp after creating new partition
    Christopher Murphy Level 3 Level 3 (525 points)

    disk1's hybrid MBR is wrong. You don't have an 07 entry for Windows marked bootable. So you need to make a new one adding partitions 2 3 4 and marking 4 bootable.

  • 332. Re: Repairing Boot Camp after creating new partition
    ysuhaas Level 1 Level 1 (0 points)

    Hey Christopher, I ran into a similar problem with the OP when I tried to shrink my OS X volume and reboot into Windows 8 and extend its volume. It looked like it wrecked my MBR, but I followed your instructions and I thought it was fixed. However, when I try to boot into Windows now, it gives me a "Missing operating system" error. Is this something that can be fixed by changing the MBR or partition table, or is iit permanant data loss? Thanks in advance...

  • 333. Re: Repairing Boot Camp after creating new partition
    Christopher Murphy Level 3 Level 3 (525 points)

    No idea based on the information provided. I need to see the MBR and GPT tables.

    sudo fdisk /dev/disk0

    sudo gpt -r -vv show disk0

  • 334. Re: Repairing Boot Camp after creating new partition
    ysuhaas Level 1 Level 1 (0 points)

    sudo fdisk /dev/disk0


    Disk: /dev/disk0geometry: 14751/255/63 [236978176 sectors]

    Signature: 0xAA55

             Starting       Ending

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

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

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

    *2: 07 1023 254  63 - 1023 254  63 [ 187226112 -   49750016] 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     

     

    sudo gpt -r -vv show disk0

     

    gpt show: disk0: mediasize=121332826112; sectorsize=512; blocks=236978176

    gpt show: disk0: Suspicious MBR at sector 0

    gpt show: disk0: Pri GPT at sector 1

    gpt show: disk0: Sec GPT at sector 236978175

              start           size  index     contents

                   0               1                MBR

                   1               1                Pri GPT header

                   2              32               Pri GPT table

                  34               6        

                  40       409600      1       GPT part - GUID

           409640  156250000      2       GPT part - GUID

      156659640     1269536      3       GPT part - GUID

      157929176   29296936        

      187226112   49750016      4       GPT part - GUID

      236976128          2015        

      236978143             32               Sec GPT table

      236978175              1                Sec GPT header


  • 335. Re: Repairing Boot Camp after creating new partition
    Christopher Murphy Level 3 Level 3 (525 points)

    The MBR and GPT are OK, although there isn't an entry for OS X in the MBR which means you won't be able to see the OS X volume from Windows. If that matters you'll want to redo the hybrid MBR to including partitions 2 3 4, marking 4 as bootable. Otherwise, if you don't need to read OS X files from within Windows, then I'd leave it the way it is.

     

    Next you'll need to boot a Windows DVD, and use Startup Repair.

  • 336. Re: Repairing Boot Camp after creating new partition
    ysuhaas Level 1 Level 1 (0 points)

    WIndows 8 doesn't have Startup Repair, so I tried an option called "Automatic Repair", which did nothing, so then I tried bootrec.exe and FixMbr and RebuildBCD, which also did nothing. I ended up just deleting the WIndows partition, but do I need to do anything to fix the hybrid MBR at this point?

  • 337. Re: Repairing Boot Camp after creating new partition
    Christopher Murphy Level 3 Level 3 (525 points)

    Depends on how the Windows partition was deleted. If you use Boot Camp Assistant, no. If you used something else, probably.

  • 338. Re: Repairing Boot Camp after creating new partition
    ysuhaas Level 1 Level 1 (0 points)

    Disk Utility?

  • 339. Re: Repairing Boot Camp after creating new partition
    Christopher Murphy Level 3 Level 3 (525 points)

    sudo fdisk /dev/disk0

     

    If you have a single xEE entry then it's fine. If there's more than one, it can be removed with gdisk by going to the expert menu and creating a new protective MBR, then writing out the new table(s).

  • 340. Re: Repairing Boot Camp after creating new partition
    Marionumber1 Level 1 Level 1 (0 points)

    I have another question related to this. Will just using gparted convert the hybrid MBR into a protective MBR, or do I have to edit the partition table to do that?

  • 341. Re: Repairing Boot Camp after creating new partition
    Christopher Murphy Level 3 Level 3 (525 points)

    gparted uses parted, which upon altering a GPT will always remove the hyrid MBR and replace it with a protective MBR.

  • 342. Re: Repairing Boot Camp after creating new partition
    Marionumber1 Level 1 Level 1 (0 points)

    I know that, but does it remove the hybrid MBR just by viewing the disk?

  • 343. Re: Repairing Boot Camp after creating new partition
    Christopher Murphy Level 3 Level 3 (525 points)

    It shouldn't. In my experience so far, if the first MBR entry is type 0xEE, then parted ignores the MBR in favor of the GPT, and shows the GPT without modifying either MBR or GPT until you tell it to (I think it uses the word Apply).

  • 344. Re: Repairing Boot Camp after creating new partition
    docileninja Level 1 Level 1 (0 points)

    Hello Christopher -

     

    I have this same problem but I am concerned about changing the hybrid MBR settings. Do you always use "5" while in gdisk?

     

    Edit: Sorry replied to wrong post! X/

1 21 22 23 24 25 Previous Next