Comment 5 for bug 107326

Revision history for this message
Richard Laager (rlaager) wrote :

This is still a problem with Gutsy. I have a 64-bit machine with a 2.25 TB array (hardware RAID 5 of four 750 GB drives). The installer is "syncing" the GPT label into an msdos label. I think everyone agrees this is wrong, but it was supposedly done for compatibility with Apple's software. See bug #46853 as NowakPL pointed out. In that bug report, there's a comment [0] which says, "Until an EFI-aware GRUB installation is possible, it would be best if Ubiquity would sync MBR and GPT and ensure the proper boot partition type is set." The key part is the first phrase.

The sync patch was accepted for parted 1.7.1-3ubuntu3 on 2007-03-07 [1]. The next day [2], the grub GPT patch was accepted. I'm not sure the former is needed, as the latter works--grub supports GPT now.

I was able to install and use grub on this drive (greater than 2 TB) with Gutsy, as follows:
1. I booted the Gutsy installer and went through the partitioning screen to set things up the way I wanted them (mainly so the installer saved my settings).
2. When prompted for the timezone, I dropped into the shell in the installer, turned off the swap partition, and dismounted the stuff under and including /target. (I was just using one partition, but if you had others, you'd have things mounted under /target.)
3. I copied over /sbin/parted and /lib/libparted-1.6.so.13.11.1 (I hope I got those names right) from a Dapper installer that I booted on another machine.
4. I made the appropriate symlink in /lib: libparted-1.6.so.13 -> libparted-1.6.so.13.11.1
5. I ran the copied Dapper parted. I ran "mklabel gpt" to start over. I then re-created my partitions, being careful to make sure the partition numbers matched what I did in the installer.
6. I remounted /target and turned the swap back on.
7. I continued the install through to the grub installation phase, which strangely failed. I'm not sure why.
8. I dropped back into a shell and chroot'ed myself into /target. I then started bash, but that probably wasn't required for this to work.
9. I ran grub-install /dev/sda, copied over a /boot/grub/menu.lst from another working system, and ran update-grub.
10. I exited the chroot environment, flipped back to the installer, and rebooted. The system came up fine using GPT. I have a protective MBR, *NOT* a synched one.

There are two problems here: First, parted is synching the MBR, which violates the standard. IF (and I have no way of testing this), Macs can work with the patched grub, the sync patch should be reverted. If they can't, then those changes need to be conditionalized so that the MBR is syched ONLY if the *drive* is less than 2 TB (and presumably if there are 4 or less partitions, but that's unrelated to the problem here). Second, grub failed to install from the installer, but worked fine from the target environment. I don't know what is going on there.

[0] https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/46853/comments/8
[1] https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/46853/comments/14
[2] https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/46853/comments/15