Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Repairing Bootcamp partision after creating new partision

Hello. I tried to create and additional EFI partition on SSD to transfer files between my Bootcamp and Mac Partision on my mid-2012 macbook pro. I realized afterwards that I should have used bootcamp assistant to create that additional partition and now cannot boot into bootcamp. I deleted the extra partision without thinking and may have complicated the issue. Bootcamp is still visible and accessible from finder and the startup disk. Also my macbook has two internal drives, but the SSD with the operating systems is disk0. And windows and the mac side were both working perfectly before I gaffed.


I tried Loner T's GPT Fdisk's fix and have run into an error on the last state

stating "unable to open device '/dev/disk0' for writing! Ernno is 1! Aborting write!"


These are the steps I took below:


sudo gdisk /dev/disk0

r (revovery and transformation menu)

h (create a new hybrid MBR)

4 (add partition 4 to the hybrid)

enter(excepted the default mbr hex code of 07)

y ( set the bootable flag)

n (do not protect more partisions)

0 (print)

w (write)


then I run into the error.


Anyone have any ideas? I've included more info below







 sudo gpt -r -vv show disk0


gpt show: disk0: mediasize=1000204886016; sectorsize=512; blocks=1953525168


gpt show: disk0: Suspicious MBR at sector 0


gpt show: disk0: Pri GPT at sector 1


gpt show: disk0: Sec GPT at sector 1953525167


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


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


  1613682688   339841024      4  GPT part - EBD0A0A2-B9E5-4433-87C0-68B6B72699C7


  1953523712        1423         


  1953525135          32         Sec GPT table


  1953525167           1         Sec GPT header


sudo fdisk /dev/disk0


Disk: /dev/disk0 geometry: 121601/255/63 [1953525168 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 - 1612003512] HFS+        


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


 4: 0C 1023 254  63 - 1023 254  63 [1613682688 -  339841024] Win95 FAT32L



diskutil list


/dev/disk0 (internal, physical):


   #:                       TYPE NAME                    SIZE       IDENTIFIER


   0:      GUID_partition_scheme                        *1.0 TB     disk0


   1:                        EFI EFI                     209.7 MB   disk0s1


   2:                  Apple_HFS SSD                     825.3 GB   disk0s2


   3:                 Apple_Boot Recovery HD             650.0 MB   disk0s3


   4:       Microsoft Basic Data BOOTCAMP                174.0 GB   disk0s4




/dev/disk1 (internal, physical):


   #:                       TYPE NAME                    SIZE       IDENTIFIER


   0:      GUID_partition_scheme                        *750.2 GB   disk1


   1:                        EFI EFI                     209.7 MB   disk1s1


   2:                  Apple_HFS HDD                     749.8 GB   disk1s2


MacBook Pro 13", macOS 10.12

Posted on Jun 26, 2019 4:51 PM

Reply
Question marked as Best reply

Posted on Jun 26, 2019 5:25 PM

You need to use 2 3 4, instead of 4 in the partition list. Temporarily disable SIP using csrutil in Local Recovery -> Utilities -> Terminal.


See the Rebuild MBR section of El Capitan has deleted my bootcamp window… - Apple Community

Similar questions

5 replies

Repairing Bootcamp partision after creating new partision

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.