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 Partition gone after Yosemite upgrade

Loner T,

I can't run my Windows 7 after upgrading OS X Yosemite yesterday.

When I checked Disk Utility, there were a disk0s4 instead of the Wins partition.

I use Mac for personal purposes and Wins for work, I have to recover my all important data on Wins asap.

I didn't back up anything on Wins before upgrading Mac OS.

Your help would be highly appreciated.


This is what I got:

diskutil list

/dev/disk0

#: TYPE NAME SIZE IDENTIFIER

0: GUID_partition_scheme *250.1 GB disk0

1: EFI EFI 209.7 MB disk0s1

2: Apple_HFS Macintosh HD 56.5 GB disk0s2

3: Apple_Boot Recovery HD 650.0 MB disk0s3

4: Microsoft Basic Data 192.7 GB disk0s4

/dev/disk1

#: TYPE NAME SIZE IDENTIFIER

0: GUID_partition_scheme *524.3 MB disk1

1: Apple_HFS Java 8 Update 25 524.2 MB disk1s1


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

diskutil cs list

No CoreStorage logical volume groups found


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

sudo gpt -vv -r show /dev/disk0

gpt show: /dev/disk0: mediasize=250059350016; sectorsize=512; blocks=488397168

gpt show: /dev/disk0: Suspicious MBR at sector 0

gpt show: /dev/disk0: Pri GPT at sector 1

gpt show: /dev/disk0: Sec GPT at sector 488397167

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

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

112001024 376395776 4 GPT part - EBD0A0A2-B9E5-4433-87C0-68B6B72699C7

488396800 335

488397135 32 Sec GPT table

488397167 1 Sec GPT header


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

sudo fdisk /dev/disk0

Disk: /dev/disk0 geometry: 30401/255/63 [488397168 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 - 110321848] HFS+

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

4: 0C 1023 254 63 - 1023 254 63 [ 112001024 - 376395776] Win95 FAT32L

Posted on Nov 3, 2014 9:05 PM

Reply
29 replies

Nov 4, 2014 11:09 AM in response to Cataiday

You are the third poster who does not have a CoreStorage volume. The GPT and MBR look good.


Can you post the output of sudo dd if=/dev/rdisk0s4 count=1 2>/dev/null hexdump -C (this will check for a valid NTFS header)?


If it shows up with "R.NTFS", then try this simple fix first...


sudo fdisk -e /dev/disk0

setpid 4

07

flag 4

p

w

y


Reboot and test.

Nov 5, 2014 8:39 PM in response to Loner T

I got the "R.NTFS" in the output of sudo dd if=/dev/rdisk0s4 count=1 2>/dev/null | hexdump -C

User uploaded file

Then I tried the following commands one by one

sudo fdisk -e /dev/disk0

setpid 4

07

flag 4

p

w

y

Here is what I did.

User uploaded file

Before I created this thread to ask for your support, there were 2 options to restart OS, including Mac and something with strange name.

After following your instruction above and reboot the system, there were 3 options including Mac, Windows and still something with strange name.

I chose Windows and got an error immediately. It also asked me to press Ctrl+Alt+Delete to reboot again, but nothing happened even when I tried this many times.


I wondered if it was wrong in the first command sudo fdisk -e /dev/disk0since the message "fdisk: could not open MBR file" was there.

I need your advice on this!

Nov 6, 2014 4:28 AM in response to Cataiday

The standalone i386 boot error message can be safely ignored. If you rebooted and you have a Windows selection now, you are a bit closer.


1 Do you see a Bootcamp Volume in Finder?

2. Do you see files in the Bootcamp volume in Finder?

3. Can you select Bootcamp/Windows in System Preferences -> Startup Disk.


The next step would be to try Startup Repair. If that does not work, then Yosemite corrupted your NTFS partition which would require using Testdisk and GPT Fdisk.

Nov 6, 2014 7:33 PM in response to Loner T

I tried TeskDisk and from the very beginning it mentioned about being unable to modify my hard disk as below.

=========

Write access for this media is not available.

TestDisk won't be able to modify it.


- No partition from this disk must be mounted:

Open the Disk Utility (In Finder -> Application -> Utility folder)

and press Unmount button for each volume from this disk

- This media may be physically write-protected, check the jumpers.

==========

I tried the Disk Utility but of course I couldn't unmount the Macintosh HD partition while running on it.

User uploaded file


Anyway, I still ran TestDisk to see if all partitions would be detected correctly. It seemed good, as captured below.

User uploaded file

User uploaded file

User uploaded file

User uploaded file

All the partitions were found. Then I chose MS Data partition, keyed P and Enter to check its filesystem.

User uploaded file

The error message was same as described in the step by step guide you sent me.

The I went back and tried Deeper Search.

User uploaded file

User uploaded file

It run for hours any the analyse sector was strange at the end, something like more than 600,000,000/488,397,167. Sorry I forgot to capture this figure. However, I think Deeper Search is unnecessary if TestDisk can find all partitions.The problem is write access.


Regarding GPT FDisk (gdisk-0.8.10), after installing it I can't find where it is on my computer.


Do you have any recommendation please.

Nov 7, 2014 6:14 AM in response to Cataiday

1. Deeper Search is a sector by sector scan and can take a long time depending on the size of your disk and what is on the disk. I would let it complete (100%) and then look at the list of MS data entries and look for familiar files in in each such partition.


2. GPT Fdisk is


type gdisk

gdisk is /usr/sbin/gdisk

Nov 7, 2014 6:44 AM in response to Loner T

Thank you for your feedback Loner T

1. Yes I did let it complete after approximately 3 hours searching, and found the strange figure 600,000,000/488,397,167 (>100%).

However, I think the main problem is that TeskDisk can't modify my partition since I can't unmount the Macintosh HD while using OS X.

2. GPT Fdisk, thank you I found it. Do you have any guideline to use this tool?


Is it necessary to run both tools or only one is enough?

Nov 7, 2014 8:00 AM in response to Cataiday

Testdisk is run on the disk in read-only mode to find missing partition headers. Once found, GPT's are suitable modified and after reboot validated for correctness. It is working as designed.


If you look at the Deeper Search partitions and find partitions that have your files, then the next step is to recreate the correct partitions.

Nov 25, 2014 4:05 AM in response to Loner T

Hello Loner T,


My MBA is 11'' mid-2013.

I have almost the same problem as Cataiday.

I had a Macintosh HD partition (Mavericks) and a Windows 7 partition (BOOTCAMP). I have deleted Macintosh HD and I have installed Yosemite with a bootable USB drive (clean install).


1 Do you see a Bootcamp Volume in Finder?

Yes, I can see that.

2. Do you see files in the Bootcamp volume in Finder?

Yes, I can see all of them.

3. Can you select Bootcamp/Windows in System Preferences -> Startup Disk.

Yes, I can select it. When I do, MBA restarts and tries to boot in Windows 7 without success. The message I got is that the partition is not bootable.

Also when I start MBA and hold Option button, the only option I have is Macintosh HD.


So, is there a way to make this partition bootable again without erasing?


Thank you.

Nov 25, 2014 4:27 AM in response to ioarvan

So, I searched some threads before asking you, but now I found one answer you gave to someone.


Loner TOct 30, 2014 2:58 PM
Re: Yosemite Upgrade Broke Bootcampin response to Sixpack Jack

Typically the recovery is done, using


1. Windows Installation Media is connected to the Mac, USB or Optical Drive/DVD.

2. In OSX System Preferences -> Startup Disk -> Bootcamp -> Restart (do not select the Installation Media)

3. The BIOS layer will ask to press any key to boot from the media, which should bring up the Recovery Environment.


Here is a set of screen shots from W7 recovery - http://imgur.com/a/1DaOE#0


As far as I understand the problem is on windows boot and not in the boot camp.

In any case I will try a Windows Repair but if you have something else in mind please share it with us. 🙂


Thank you.

Windows 7 Partition gone after Yosemite upgrade

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