Charlie_Mc

Q: How do I run Win7 Startup Repair from USB to repair Bootcamp installation?

I messed up my bootcamp partition after resizing the OSX partition to give it more space so I found this fix - http://mourougan.com/2013/06/22/repairing-boot-camp-after-creating-new-partition /

 

The fix worked in that the windows partition now shows up on startup manager but when I try to load it the 'missing operating system' error message shows.

So I need to run Startup Repair from USB but when I try that from startup manager it just gives a black screen and blinking cursor, nothing happens from there...

Can anyone help with getting startup repair to load? any advice greatly appreciated.

Many Thanks

Mac mini (Late 2012), OS X Yosemite (10.10.1)

Posted on Jan 19, 2015 4:28 AM

Close

Q: How do I run Win7 Startup Repair from USB to repair Bootcamp installation?

  • All replies
  • Helpful answers

Page 1 of 3 last Next
  • by Loner T,Solvedanswer

    Loner T Loner T Jan 19, 2015 12:37 PM in response to Charlie_Mc
    Level 7 (24,800 points)
    Safari
    Jan 19, 2015 12:37 PM in response to Charlie_Mc

    The NTFS header of your Windows partition should be checked as well.

     

    Can you post the output of the following OSX Terminal commands (These do not make any changes to your partitions of files. Enter your password for the sudo commands).

     

    diskutil list

    diskutil cs list

    sudo gpt -vv -r show /dev/disk0

    sudo fdisk /dev/disk0

     

    Once the BC partition is established, a dd command will show the NTFS header.

     

    If your Windows NTFS is intact, the following steps can be used for W7/W8.

     

    1. If you have a built-in Optical drive, insert installation media, otherwise use the USB created via BCA with the installation ISO and BC drivers.

    2. Select System Preferences -> Startup Disk -> Bootcamp (Do not select the Installation Media) -> Restart.

    3. Windows should boot from the Installation Media.

    4. Use Repair Windows from the Installer window. Here is set of screen shots for W7 recovery. - http://imgur.com/a/1DaOE#0.

  • by Charlie_Mc,

    Charlie_Mc Charlie_Mc Jan 19, 2015 2:08 PM in response to Loner T
    Level 1 (1 points)
    Jan 19, 2015 2:08 PM in response to Loner T

    Many thanks for your reply, here are the results of the commands -


    diskutil list

    Screen Shot 2015-01-19 at 21.56.02.png

    diskutil cs list

    No CoreStorage logical volume groups found


    sudo gpt -vv -r show /dev/disk0

    Screen Shot 2015-01-19 at 21.58.42.png

    sudo fdisk /dev/disk0

    Screen Shot 2015-01-19 at 22.00.18.png

    I tried to select Bootcamp in System Preferences -> Startup Disk -> but it does not show up there, it only shows up in Startup Manager when I restart and hold alt. Is there a way I can get it to show up again in Startup Disk?

  • by Loner T,

    Loner T Loner T Jan 19, 2015 2:18 PM in response to Charlie_Mc
    Level 7 (24,800 points)
    Safari
    Jan 19, 2015 2:18 PM in response to Charlie_Mc

    Apple NTFS driver, which allows System Preferences -> Startup Disk to show the Windows partition cannot find a NTFS header. It shows up in Bootmanager using the Alt key due to the entry in Fdisk output at item #2.

     

    Can you post the output of the following command? It dumps the NTFS header on the Disk0s4 slice.

     

    sudo dd if=/dev/rdisk0s4 count=1 2>/dev/null | hexdump -C

  • by Charlie_Mc,

    Charlie_Mc Charlie_Mc Jan 19, 2015 3:31 PM in response to Loner T
    Level 1 (1 points)
    Jan 19, 2015 3:31 PM in response to Loner T

    Ok heres the output -

    Screen Shot 2015-01-19 at 23.28.07.png

  • by Loner T,Helpful

    Loner T Loner T Jan 19, 2015 4:01 PM in response to Charlie_Mc
    Level 7 (24,800 points)
    Safari
    Jan 19, 2015 4:01 PM in response to Charlie_Mc

    The NTFS header is missing. It is very likely that it is sitting between GPT3 and GPT4.

     

    Can you look at Re: Please help, lost windows after Yosemite upgrade as reference and start with the Testdisk part? Once Testdisk finds the correct NTFS header, GPT Fdisk can be used to correct GPT4 to get Windows working again.

  • by Charlie_Mc,

    Charlie_Mc Charlie_Mc Jan 20, 2015 3:39 AM in response to Loner T
    Level 1 (1 points)
    Jan 20, 2015 3:39 AM in response to Loner T

    Ok here are the outputs from my testdisk -

    Screen Shot 2015-01-20 at 11.31.39.png

    Screen Shot 2015-01-20 at 11.26.30.png

    Should I go ahead and do the Gdisk part described in that thread using my values from the first screen shot? -

     

    Rebuild GPT4 using start/end offsets

     

    1. Sudo gdisk /dev/rdisk0
    2. P  (print the full list of parts)
    3. D  (delete)
    4. 4  (part 4)
    5. N  (new part)
    6. 4   (part 4)
    7. 743868416 - Start offset in bytes  (start point for Bootcamp part)
    8. +232904697 (Size offset as opposed to End offset)
    9. 0700     (Windows part type)
    10. P           (print list of all parts just to see what changes will be made)
    11. W         (Write the new GPT)
    12. Y           (Yes! really write the new GPT)

      This will delete and re-write the GPT partition info for /dev/disk0s4.

  • by Loner T,Helpful

    Loner T Loner T Jan 20, 2015 5:05 AM in response to Charlie_Mc
    Level 7 (24,800 points)
    Safari
    Jan 20, 2015 5:05 AM in response to Charlie_Mc

    The difference between the end of GPT3 (694408016) and start of NTFS that you have found (743868416) is about 49460400 sectors

    ( ~ 24GB). Was that the disk space you were planning to use for re-sizing Windows? It will be lost space, between GPT3 and GPT4, once you make your changes. If you are willing to accept that 'loss', yes, you can do both Gdisk steps, using your values of start/size.

     

    The only method to get it back is to backup OS X, backup Windows (using Winclone or Camptune - Windows backup requires additional work and has some additional challenges), erase the internal drive, restore OS X and then restore Windows.

     

    I recommend that you recover Windows first and then decide.

  • by Charlie_Mc,

    Charlie_Mc Charlie_Mc Jan 20, 2015 5:19 AM in response to Loner T
    Level 1 (1 points)
    Jan 20, 2015 5:19 AM in response to Loner T

    Ok, yes the 24GB was going to be added to windows.

    I shall recover Windows and then look into backing it up with Winclone or Camptune so I can erase and restore.

    I have OS X backed up with Time Machine, is a back up with this sufficient for this task?

  • by Charlie_Mc,

    Charlie_Mc Charlie_Mc Jan 20, 2015 5:28 AM in response to Loner T
    Level 1 (1 points)
    Jan 20, 2015 5:28 AM in response to Loner T

    Should I also follow these instructions from the thread? -

     

    Rebuild MBR to match the new GPT information thus resetting the Hybrid MBR. Use defaults for other questions (like partition codes).

    1. Sudo gdisk /dev/disk0
    2. P  (Print list of parts)
    3. R   (Recover)
    4. H (chooses Hybrid)
    5. Partitions numbers to be hybridized: 2 3 4
    6. Y (Good for GRUB question)
    7. N (part 2 boot flag)
    8. N (part 3 boot flag)
    9. Y  (part 4 boot flag make NTFS bootable partition)
    10. W  (Write the new MBR)
    11. Y    (Yes! write the new MBR)
    12. Reboot
  • by Loner T,

    Loner T Loner T Jan 20, 2015 5:36 AM in response to Charlie_Mc
    Level 7 (24,800 points)
    Safari
    Jan 20, 2015 5:36 AM in response to Charlie_Mc
    I have OS X backed up with Time Machine, is a back up with this sufficient for this task?

    TM is the easiest source to use for backup/restore.

     

    Charlie_Mc wrote:

     

    Should I also follow these instructions from the thread? -

     

    Rebuild MBR to match the new GPT information thus resetting the Hybrid MBR.

    Yes, but can you also post the output of the following command (before or after these steps is fine).

     

    sudo dd if=/dev/rdisk0s4 count=1 2>/dev/null | hexdump -C

  • by Charlie_Mc,

    Charlie_Mc Charlie_Mc Jan 20, 2015 5:40 AM in response to Loner T
    Level 1 (1 points)
    Jan 20, 2015 5:40 AM in response to Loner T

    Heres the output -

     

    Screen Shot 2015-01-20 at 13.39.12.png

  • by Loner T,

    Loner T Loner T Jan 20, 2015 5:41 AM in response to Charlie_Mc
    Level 7 (24,800 points)
    Safari
    Jan 20, 2015 5:41 AM in response to Charlie_Mc

    The 'R.NTFS' is a good thing. . Please continue with rest of the steps and test. If you see any error messages, please post back.

  • by Charlie_Mc,

    Charlie_Mc Charlie_Mc Jan 20, 2015 5:56 AM in response to Loner T
    Level 1 (1 points)
    Jan 20, 2015 5:56 AM in response to Loner T

    All the tests worked I can now see Bootcamp and files again in finder and Startup Disk

    I will go ahead and do Windows Startup repair, many thanks for you awesome assistance!

  • by Loner T,

    Loner T Loner T Jan 20, 2015 6:26 AM in response to Charlie_Mc
    Level 7 (24,800 points)
    Safari
    Jan 20, 2015 6:26 AM in response to Charlie_Mc

    Are you unable to use System Preferences -> Startup Disk -> Bootcamp -> Restart?

Page 1 of 3 last Next