You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

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

Windows 7 not bootable after upgrade

Hello All,


I have just upgraded to Maverick OS X 10.9 (13A603). Now as many of the others I am unable to boot into my Windows 7.
The partition is NOT LOST. I can still see the partions and the files in the Windows HD just cannot boot with it.


I guess it can be easily fixed using gdisk for experts.

Anyhelp in this matter is greatly appreciated.


My outputs are:


$ diskutil list

/dev/disk0

#: TYPE NAME SIZE IDENTIFIER

0: GUID_partition_scheme *121.3 GB disk0

1: EFI EFI 209.7 MB disk0s1

2: Apple_HFS Macintosh HD 35.3 GB disk0s2

3: Microsoft Basic Data Data HD 34.7 GB disk0s3

4: Microsoft Basic Data Windows7 HD 50.5 GB disk0s4

5: Apple_Boot Recovery HD 650.0 MB disk0s5


=========


$ 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 - C12A7328-F81F-11D2-BA4B-00A0C93EC93B

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

69313808 1269544 5 GPT part - 426F6F74-0000-11AA-AA11-00306543ECAC

70583352 968

70584320 67815424 3 GPT part - EBD0A0A2-B9E5-4433-87C0-68B6B72699C7

138399744 98576384 4 GPT part - EBD0A0A2-B9E5-4433-87C0-68B6B72699C7

236976128 2015

236978143 32 Sec GPT table

236978175 1 Sec GPT header


=========


$ sudo fdisk /dev/disk0

Password:

Disk: /dev/disk0 geometry: 14751/255/63 [236978176 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 - 68904168] HFS+

3: 07 1023 254 63 - 1023 254 63 [ 70584320 - 67815424] HPFS/QNX/AUX

4: 07 1023 254 63 - 1023 254 63 [ 138399744 - 98576384] HPFS/QNX/AUX


=========


$ sudo gdisk /dev/disk0

Password:

GPT fdisk (gdisk) version 0.8.8



Warning: Devices opened with shared lock will not have their

partition table automatically reloaded!

Partition table scan:

MBR: hybrid

BSD: not present

APM: not present

GPT: present



Found valid GPT with hybrid MBR; using GPT.


Command (? for help): p

Disk /dev/disk0: 236978176 sectors, 113.0 GiB

Logical sector size: 512 bytes

Disk identifier (GUID): C1909920-CFA1-44C9-A845-1ABF1B7F5E65

Partition table holds up to 128 entries

First usable sector is 34, last usable sector is 236978142

Partitions will be aligned on 8-sector boundaries

Total free space is 2989 sectors (1.5 MiB)



Number Start (sector) End (sector) Size Code Name

1 40 409639 200.0 MiB EF00 EFI

2 409640 69313807 32.9 GiB AF00 Macintosh HD

3 70584320 138399743 32.3 GiB 0700 Data HD

4 138399744 236976127 47.0 GiB 0700 Windows7 HD

5 69313808 70583351 619.9 MiB AB00 Recovery HD



=========


I do not know what to do here.


Please help.


Thanks alot

MacBook Air (13-INCH, MID 2011), Mac OS X (10.7.4)

Posted on Dec 7, 2013 12:35 AM

Reply
18 replies

Dec 7, 2013 1:14 AM in response to write.to.salman

I think my problem is that my Windows HD partition is not marked as Bootable.

In the gdisk i see this in the recovery option


Recovery/transformation command (? for help): o


Disk size is 236978176 sectors (113.0 GiB)

MBR disk identifier: 0x1D94FD6E

MBR partitions:


Number Boot Start Sector End Sector Status Code

1 1 409639 primary 0xEE

2 409640 69313807 primary 0xAF

3 70584320 138399743 primary 0x07

4 138399744 236976127 primary 0x07


No partition is marked as bootable.


Learning from Christopher's learnings, may be i just need to create a new empty GUID partition table in gdisk by pressing o


Add new partitions (by pressing n) EFI (dont know what it is for), Macintosh HD, Windows HD and Recovery HD into it and make Windows HD bootable.


Am I correct ?


Another issue that can be is that my two drives have completely same GUID.

Is this ok?


May be it is causing issue.

User uploaded file

Dec 7, 2013 1:31 AM in response to Number88

At the time i bought Laptop i did partitions.

So in Mid of 2011.


I partitioned my Macintosh HD in three ways.


- Mac

- Data HD

- Windows


It worked fine all the time since 2011. Data HD is FAT EX

I followed tutorial to do it.


Even right now i see my all partitions and their sizes are same and their files are accessible, just i cannot boot into Windows.

Dec 7, 2013 1:39 AM in response to write.to.salman

You definitely don't want to create a new GPT.

I'm really not 100% sure here as I try to avoid exceeding the 4 partition limit imposed by the hybrid mbr, however, what I would do is to create a new hybrid mbr using gdisk.

In that new hybrid mbr I would include EFI partition (answer Y when asked) and I would also include partitions 2, 3 & 4 with default partition types.

The only one that you should answer Y to is when asked to make partition 4 bootable (answering N to the rest).

(This new hybrid mbr would be that same as your present mbr except that partition 4 would be bootable, however I'm not sure whether there is a shorter way of doing it).


The area I'm unsure about is which partitions to include in the new mbr, though I think the above is probably correct.

Don't forget to write the new details to disk (ie type w then enter then answer Y).


Please note that if I'm wrong here there may be repercussions, though probably not unfixable.


Good luck!

Dec 7, 2013 1:50 AM in response to Number88

Thanks for your reply.

Which command creates a new hybrid MBR ?


Command (? for help): ?

b back up GPT data to a file

c change a partition's name

d delete a partition

i show detailed information on a partition

l list known partition types

n add a new partition

o create a new empty GUID partition table (GPT)

p print the partition table

q quit without saving changes

r recovery and transformation options (experts only)

s sort partitions

t change a partition's type code

v verify disk

w write table to disk and exit

x extra functionality (experts only)

? print this menu

Dec 7, 2013 2:00 AM in response to Number88

The problem is that it is not letting me create it with 4 partitions


Recovery/transformation command (? for help): h


WARNING! Hybrid MBRs are flaky and dangerous! If you decide not to use one,

just hit the Enter key at the below prompt and your MBR partition table will

be untouched.


Type from one to three GPT partition numbers, separated by spaces, to be

added to the hybrid MBR, in sequence: 1 2 3 4

Place EFI GPT (0xEE) partition first in MBR (good for GRUB)? (Y/N): Y


Creating entry for GPT partition #1 (MBR partition #2)

Enter an MBR hex code (default EF): EF

Set the bootable flag? (Y/N): N


Creating entry for GPT partition #2 (MBR partition #3)

Enter an MBR hex code (default AF): AF

Set the bootable flag? (Y/N): N


Creating entry for GPT partition #3 (MBR partition #4)

Enter an MBR hex code (default 07): 07

Set the bootable flag? (Y/N): N


But it just stops at the Data HD and does not ask me anything about the Windows HD

Dec 7, 2013 1:36 PM in response to write.to.salman

So it's a really non-standard layout that isn't supported. For one you have five partitions. Two are "microsoft basic data" types, but I can't tell which contains Windows and which is an extra. I'm uncertain of the advantage of having two NTFS partitions on a single disk like this, but whatever. The other thing is that Recovery HD is in the normal position in terms of sectors, but in terms of order in the GPT it's last - that's a first for me, I'm not sure how that would happen. There's nothing inherently wrong with this, but it's just not expected and something had to have done this, it doesn't happen on its own.


Based on fdisk results:


3: 07 1023 254 63 - 1023 254 63 [ 70584320 - 67815424]

4: 07 1023 254 63 - 1023 254 63 [ 138399744 - 98576384]


The very basic problem is that neither has a * to indicate it's bootable. The easiest way to fix it is to use fdisk -e to edit the partition table, and then use the command flag in fdisk on the partition that you want bootable. So


print

flag 4

write


Is the approximate sequence I think, assuming partition 4 contains the Windows you want bootable.

Feb 11, 2014 7:32 AM in response to Number88

Hi all,


as write.to.salman I also upgraded to maverikcs and not able anymore to boot on windows 7.

I tried to follow step by step your suggestion, anyway whenever I try to boot into windows it says " operating system not available".


What I did is:

i)

Na-If-Mac-Mini:~ naif$ diskutil list

/dev/disk0

#: TYPE NAME SIZE IDENTIFIER

0: GUID_partition_scheme *500.1 GB disk0

1: EFI EFI 209.7 MB disk0s1

2: Apple_HFS Macintosh HD 248.5 GB disk0s2

3: Apple_Boot Recovery HD 650.0 MB disk0s3

4: Microsoft Basic Data 250.8 GB disk0s4

ii)

Na-If-Mac-Mini:~ naif$ 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 485320880 2 GPT part - 48465300-0000-11AA-AA11-00306543ECAC

485730520 1269544 3 GPT part - 426F6F74-0000-11AA-AA11-00306543ECAC

487000064 489773056 4 GPT part - EBD0A0A2-B9E5-4433-87C0-68B6B72699C7

976773120 15

976773135 32 Sec GPT table

976773167 1 Sec GPT header

Na-If-Mac-Mini:~ naif$ 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 - 487000063] <Unknown ID>

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

Na-If-Mac-Mini:~ naif$








Na-If-Mac-Mini:~ naif$ 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 485320880 2 GPT part - 48465300-0000-11AA-AA11-00306543ECAC

485730520 1269544 3 GPT part - 426F6F74-0000-11AA-AA11-00306543ECAC

487000064 489773056 4 GPT part - EBD0A0A2-B9E5-4433-87C0-68B6B72699C7

976773120 15

976773135 32 Sec GPT table

976773167 1 Sec GPT header

Na-If-Mac-Mini:~ naif$

iv)sudo gdisk /dev/disk0 pressed r

v) pressed h then enter

vi) 2 3 4

vii) pressed enter for all of them and Y in "set bootable flag just for 4"

viii) N

Unfortunatly as soon as I reboot and try to boot into widows 7 it says as mentioned erlier "no operating system available". Do you any clues and suggestions on how I could solve it?

Thank you in advance, you have already been very helpful

Windows 7 not bootable after upgrade

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