Your computer uses two partition tables stored on your internal drive. The first is the Master Boot Record (MBR) partition table and the second is the GUID Partition Table (GPT). You used the commands fdisk
and gpt
to print out most of the contents of the MBR partition table and GPT, respectively.
For the most part, Windows (booted via BIOS) ignores the GPT and uses the MBR table exclusively to determine the partitions on your internal drive. For Macs, the usual requirement is for the first partition in the MBR table to have an id=EE
. Also this partition should start at a Logical Block Address (LBA) of 1 and end at the same LBA as the EFI partition in the GPT. (The EFI partition has an GUID=C12A7328-F81F-11D2-BA4B-00A0C93EC93B
.)
Your MBR partition table contains the following problems:
- Your first partition (id=
EE
) extends past the EFI partition in the
GPT. In fact, this partition covers the first three partitions in the
GPT.
- The last partition (number 4) is empty. This probably where the HFS+
partition information was stored before you updated to Windows 10.
- The partitions are not in ascending order. I do not know if this one
has to be fixed. For now, I will ignore this problem.
One of the easiest commands that can fix these types of problems is gdisk
. This command can be found in most Linux installs. Below is a example of how to use the command to fix your Mac. In the example, this command was run under OS X. I assume you will be using Linux, therefore you should substitute /dev/sda
for /dev/disk0
.
Steelhead:~ davidanderson$ gdisk /dev/disk0
GPT fdisk (gdisk) version 1.0.1
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): r
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: 5 4 2
Place EFI GPT (0xEE) partition first in MBR (good for GRUB)? (Y/N): y
Creating entry for GPT partition #5 (MBR partition #2)
Enter an MBR hex code (default 07): 07
Set the bootable flag? (Y/N): y
Creating entry for GPT partition #4 (MBR partition #3)
Enter an MBR hex code (default 83): 83
Set the bootable flag? (Y/N): n
Creating entry for GPT partition #2 (MBR partition #4)
Enter an MBR hex code (default AF): af
Set the bootable flag? (Y/N): n
Recovery/transformation 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/disk0.
Warning: Devices opened with shared lock will not have their
partition table automatically reloaded!
Warning: The kernel may continue to use old or deleted partitions.
You should reboot or remove the drive.
The operation has completed successfully.
Steelhead:~ davidanderson$
When finished the output from sudo fdisk /dev/disk0
should show the following values in the #, id, start and size columns.
#: id start size
------------------------------
1: EE 1 409639
*2: 07 744597504 214845440
3: 83 451624920 292970696
4: AF 409640 449945744
If your values are different, update your question and report the differences.
diskutil list
,diskutil cs list
,sudo gpt -r show /dev/disk0
andsudo fdisk /dev/disk0
. These commands will not change your computer. Some may ask for your login password. This is normal.gdisk
command. Boot to Linux and open a Terminal window. At the prompt, enter the commandgdisk
and report back if the command was found.