more hybrid MBR bugs
more hybrid MBR bugs
- Subject: more hybrid MBR bugs
- From: Chris Murphy <email@hidden>
- Date: Mon, 28 Oct 2013 11:40:01 -0600
A lot of people on various forums are losing their Windows volumes now that 10.9 is out. And it seems to be the same sorts of lingering problems from 10.7 and 10.8 that still have not been fixed. I'm seeing evidence of two kinds of really bad behaviors on the part of the installer:
1. The user resizes in Disk Utility, to shrink the OS X volume. Reboots to Windows and resizes NTFS to fill the free space, which of course only updates the MBR. The GPT is not updated. But everything continues to work OK until there's a major OS upgrade, and then Windows breaks.
I'm going to guess that the installer calls diskutil repairdisk, and if so when I separately call diskutil repairdisk on a disk that has an unsynced hybrid MBR, it notices this and asks me if I want it fixed. Well the installer doesn't ask, it just stomps on the correct MBR, and replaces it with the wrong information in the GPT.
This is the fundamental problem with hybrid MBRs. They can't be updated automatically once the MBR and GPT are no longer in sync, or you get data loss, which is what's happening here. The very fact the MBR is not matching the GPT tells us something that only understands MBRs has changed the MBR. Otherwise it would also have changed the GPT to match. Therefore we can only trust the MBR by default.
So the current behavior of the installer is simply wrong and is causing data loss, and has been now for > two years.
2. The user is on OS X 10.6 which does not have a Recovery HD, and upon upgrading they get a Recovery HD. But the installer appears to change the MBR #3 entry (Windows) to the #4 entry, and in so doing doesn't transfer the correct type code or the boot flag. It goes from 07 to 0C, and from bootable to not bootable. And hence Windows isn't bootable.
So this is a case of not correctly modifying the MBR after adding Recovery HD.
Chris Murphy
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Filesystem-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden