Grub2 not recognise GPT when presence hybrid MBR
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
grub2 (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
Root issue:
grub ignore protective GPT record if that record is not the first one in MBR.
Need to correct:
If protective GPT record appears on any place in MBR - grub must consider system as GPT.
I have hybrid GPT/MBR. Hybrid MBR contains protective record 0xEE but that record is NOT first.
Here is output of gdisk (hybrid MBR):
Number Boot Start Sector End Sector Status Code
1 468992 101480447 primary 0x07
2 234375168 234569727 primary 0xEF
3 * 550782882 574927413 primary 0x83
4 1 468991 primary 0xEE
gdisk (GPT):
Number Start (sector) End (sector) Size Code Name
1 2048 206847 100.0 MiB EF00 EFI system partition
2 206848 468991 128.0 MiB 0C01 Microsoft reserved part
3 468992 101480447 48.2 GiB 0700 win7
4 101480448 138344447 17.6 GiB AF00 other
5 390625280 527343615 65.2 GiB 8301 copyfilesWIN7
6 527343616 550780927 11.2 GiB AF00 backupfile
7 581042176 625141759 21.0 GiB 2700 Samsung_diag
8 138344448 234375167 45.8 GiB 0700 DATA
11 574927414 581042175 2.9 GiB 8200
12 234375168 234569727 95.0 MiB EF02 grub
13 550782882 574927413 11.5 GiB 0700 linux
After that it result in such errors:
root@helena:~# grub-install /dev/sda
/usr/sbin/
/usr/sbin/
/usr/sbin/
invoking grub-mkconfig manually gives:
root@helena:~# grub-mkconfig -o test.conf
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-
Found initrd image: /boot/initrd.
Found linux image: /boot/vmlinuz-
Found initrd image: /boot/initrd.
Found linux image: /boot/vmlinuz-
Found initrd image: /boot/initrd.
Found linux image: /boot/vmlinuz-
Found initrd image: /boot/initrd.
Found memtest86+ image: /boot/memtest86
grub-probe: error: cannot find a GRUB drive for /dev/sda4. Check your device.map.
grub-probe: error: cannot find a GRUB drive for /dev/sda5. Check your device.map.
grub-probe: error: cannot find a GRUB drive for /dev/sda6. Check your device.map.
grub-probe: error: cannot find a GRUB drive for /dev/sda7. Check your device.map.
done
I have tried diferent approach - was removed hybrid MBR (retained only protective record). After that grub-install succeed. After that I have created hybrid MBR (the same as above).
But after reboot I have got "grub rescue" prompt and error: no such partition.
root@helena:~# lsb_release -rd
Description: Ubuntu 12.04 LTS
Release: 12.04
root@helena:~# apt-cache policy grub-pc
grub-pc:
Installed: 1.99-21ubuntu3
Candidate: 1.99-21ubuntu3
Version table:
*** 1.99-21ubuntu3 0
500 http://
100 /var/lib/
ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: grub-pc 1.99-21ubuntu3
ProcVersionSign
Uname: Linux 2.6.38-14-generic x86_64
ApportVersion: 2.0.1-0ubuntu7
Architecture: amd64
Date: Fri May 11 17:45:17 2012
InstallationMedia: Ubuntu 11.04 "Natty Narwhal" - Release amd64+mac (20110426)
SourcePackage: grub2
UpgradeStatus: Upgraded to precise on 2012-05-07 (3 days ago)
---
ApportVersion: 2.0.1-0ubuntu13
Architecture: amd64
DistroRelease: Ubuntu 12.04
InstallCmdLine: file=/cdrom/
InstallationMedia: Ubuntu 11.04 "Natty Narwhal" - Release amd64+mac (20110426)
Package: ubiquity 2.10.20
PackageArchitec
ProcVersionSign
Tags: precise
Uname: Linux 3.2.0-30-generic x86_64
UpgradeStatus: Upgraded to precise on 2012-05-07 (131 days ago)
UserGroups:
information type: | Public → Public Security |
Hello
Do you still have this issue with a fresh 12.04.1 liveCD ?
if yes, please indicate your Boot-Info URL ( https:/ /help.ubuntu. com/community/ Boot-Info )