mikgigs

Q: restore original gpt from broken mbr in bootcamp

Hello,

 

I have a very adventurous trouble with bootcamp that almost bricked my computer.

I have installed bootcamp with Windows 7 on my Mac, since I need Windows to demo some software on OpenGL.

The problems have started when I have splitted bootcamp drive in two using Windows administrative tools to make C and D drives

since my programs were hard-coded to work from C and D drives...

And then BAM!

the windows became always crashing. and I cannot access the Macintosh HD anymore.

Moreover, it seems that Windows Administrative partitioning tool destroys the boot record(probably some hybrid MBR/GUID).

Well, the obvious (not a ) solution is to erase everything and make clean install.

In my case I would like to restore back to OSX  on the installation as it was previous to bootcamp, since there are a lot of programs installed, settings and files that unfortunately need.

I do not need BootCamp Window partitions and information there.

 

So, is there a tool of system restore disk, that could repair GUID, repair/resize partitions such as gpt gptsync, and fdisk that could restore those.

None of those those been used yet.

Or maybe there is another one.

 

I will make a not that neither OSX or Windows is working.

What I could use in the moment is that I could go in AppleStore and ask for CD drive, or plug their network with restore Images.

Unfortunately, mac associates there do not support issues with bootcamp and this is my basis for repair.

Could help me with some advice or routine how to restore my mac,

 

Thank you.

Posted on Feb 1, 2015 7:06 AM

Close

Q: restore original gpt from broken mbr in bootcamp

  • All replies
  • Helpful answers

Previous Page 2
  • by Loner T,

    Loner T Loner T Feb 3, 2015 4:05 AM in response to mikgigs
    Level 7 (23,970 points)
    Safari
    Feb 3, 2015 4:05 AM in response to mikgigs

    Excellent work mikgigs.

  • by Zlop,

    Zlop Zlop Jul 19, 2015 6:12 AM in response to Loner T
    Level 1 (0 points)
    Jul 19, 2015 6:12 AM in response to Loner T

    Mr Loner T, could I please ask you for some help.

    I'm having major problem attempting to install Windows on my MBPro 2011.

    I keep getting stuck on gpt-mbr error when trying to select the drive during EFIBoot instalation from the USB.

    My Superdive is inaccessible and using the USB is the only way.

    Please if there is any way I can get around it using gdisk let me know. I tried following instructions from here: http://macriot.com/mcrt/?p=2362

    But I'm unable to finish the process, it says it won't save on the disk with the following:

     

    Expert command (? for help): w

    Final checks complete. About to write GPT data. THIS WILL OVERWRITE EXISTING PARTITIONS!!

    Do you want to proceed? (Y/N): y

    OK; writing new GUID partition table (GPT) to /dev/disk0s2.

    Warning: Devices opened with shared lock will not have their partition table automatically reloaded!

    Unable to open device ‘/dev/disk0s2′ for writing! Errno is 16! Aborting write!


    Any help is welcome, help a fellow human who is going crazy with this.



  • by Loner T,

    Loner T Loner T Jul 19, 2015 6:39 AM in response to Zlop
    Level 7 (23,970 points)
    Safari
    Jul 19, 2015 6:39 AM in response to Zlop

    Zlop wrote:

     

    OK; writing new GUID partition table (GPT) to /dev/disk0s2.

    Warning: Devices opened with shared lock will not have their partition table automatically reloaded!

    Unable to open device ‘/dev/disk0s2′ for writing! Errno is 16! Aborting write!

    You need to use /dev/rdisk0, not /dev/disk0s2. The MBR is written to the entire disk.

  • by Zlop,

    Zlop Zlop Jul 19, 2015 6:52 AM in response to Loner T
    Level 1 (0 points)
    Jul 19, 2015 6:52 AM in response to Loner T

    Ok, I'll give that a go, thank you for replying.

    One more question, my Superdive is not working and I don't have the option in Bootcamp to use the USB to install.

    I knowI can get it and have done so by editing the info.plst file, but is that something I should do and is it going to create problems later on?

    Basically if it isn't for whatever reason an option given on my Macbook and my optical drive does not work - then perhaps I need to find a different way or simply give up. Or is it ok to edit the info.plst file and proceed wih the EFI Boot installation of Windows?

     

    Thank you so much.

  • by Loner T,

    Loner T Loner T Jul 19, 2015 10:00 AM in response to Zlop
    Level 7 (23,970 points)
    Safari
    Jul 19, 2015 10:00 AM in response to Zlop

    Was your Logic Board recently replaced by Apple due to the AMD GPU issue?

  • by Zlop,

    Zlop Zlop Jul 19, 2015 10:05 AM in response to Loner T
    Level 1 (0 points)
    Jul 19, 2015 10:05 AM in response to Loner T

    I don't think so. Thought I've only recently just bought this machine second hand. Your tip for gdisk worked btw, thank you. I'm proceedinf with the installation now, I'll see how far I get this time.

  • by Sivesh,

    Sivesh Sivesh Oct 28, 2015 12:16 PM in response to Loner T
    Level 1 (0 points)
    Oct 28, 2015 12:16 PM in response to Loner T

    Hi Loner T

    I am one of the many having problems booting to BootCamp after resizing my partition.

    I am having a similar problem to Zlop. When following your instructions I get "Unable to open device '/dev/rdisk0' for writing! Errno is 1! Aborting write!" after entering "w" for the final step.

    I would be very grateful if you could help me out.

    Thanks,

    Sivesh

  • by Loner T,

    Loner T Loner T Oct 28, 2015 12:54 PM in response to Sivesh
    Level 7 (23,970 points)
    Safari
    Oct 28, 2015 12:54 PM in response to Sivesh

    You are on El Capitan, which has System Integrity Protection enabled. Disable it using

     

    1. Boot into Local Recovery (Command+R).

    2. Run Utilities -> Terminal.

    3. Type csrutil enable and press Enter/Return.

    4. Reboot normally and repeat your GPT Fdisk steps.

    5. After you get Windows working repeat 1-4 with csrutil enable.

  • by Sivesh,

    Sivesh Sivesh Oct 28, 2015 1:09 PM in response to Loner T
    Level 1 (0 points)
    Oct 28, 2015 1:09 PM in response to Loner T

    Thanks very much for your prompt reply.

     

    I did steps 1-3 and they seemed to work however when I tried your steps again I still got the error I was getting earlier, is there anything else I can try?

  • by Loner T,

    Loner T Loner T Oct 28, 2015 1:15 PM in response to Sivesh
    Level 7 (23,970 points)
    Safari
    Oct 28, 2015 1:15 PM in response to Sivesh

    Can you post the output of

     

    csrutil status

     

    from OSX Terminal?

  • by Sivesh,

    Sivesh Sivesh Oct 28, 2015 1:21 PM in response to Loner T
    Level 1 (0 points)
    Oct 28, 2015 1:21 PM in response to Loner T

    Yep it's "System Integrity Protection status: enabled." going to give disabling it another go and see if it works

  • by Sivesh,

    Sivesh Sivesh Oct 28, 2015 1:33 PM in response to Loner T
    Level 1 (0 points)
    Oct 28, 2015 1:33 PM in response to Loner T

    Just repeated and it worked, I can now see the windows disk upon start up, however, now when i click on it I get the following error. Nothing happens when i press ctrl + alt + dlIMG_2667.jpg

  • by Loner T,

    Loner T Loner T Oct 28, 2015 2:01 PM in response to Sivesh
    Level 7 (23,970 points)
    Safari
    Oct 28, 2015 2:01 PM in response to Sivesh

    You will need to run Windows Startup Repair.

  • by Sivesh,

    Sivesh Sivesh Oct 28, 2015 2:12 PM in response to Loner T
    Level 1 (0 points)
    Oct 28, 2015 2:12 PM in response to Loner T

    Okay thank you so much for the help, could you advise me on what i should do to run Windows Startup Repair

  • by Loner T,

    Loner T Loner T Oct 28, 2015 2:17 PM in response to Sivesh
    Level 7 (23,970 points)
    Safari
    Oct 28, 2015 2:17 PM in response to Sivesh

    You will need to find the USB Installer which was used to install Windows on this Mac.

Previous Page 2