preseed with RAID and GPT fails to set bios_grub flag on first disk but does set it on second so install fails
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
partman-auto (Ubuntu) |
Fix Released
|
High
|
Colin Watson | ||
Lucid |
Fix Released
|
High
|
Colin Watson |
Bug Description
Binary package hint: partman-base
Hi,
Note: I am not sure this belongs in partman-base but it definitely is in one of the partman-*...
Note: This is on latest Ubuntu Lucid 10.04 LTS. The time stamp on the installer is 20081029ubuntu100.
I am doing automated install during which two 2TiB disks are partitioned to have a bios boot partition on each disk (1MiB size), then three software RAID1 devices, one for /, 20GiB, one for swap 4GiB, and one for /var (rest of space, i.e. just under 2TiB).
The snippet from the automated installation config file is this:
# Configure MD sotfware RAID and partitioning.
preseed partman-
preseed partman-auto/method string raid
preseed partman-auto/disk string "/dev/sdb /dev/sdc"
preseed partman-
preseed partman-
preseed partman-
preseed partman-md/confirm boolean true
preseed partman/
preseed partman/
preseed partman/confirm boolean true
preseed mdadm/boot_degraded boolean true
# Install GRUB on the MBR of both disks.
preseed grub-installer/
preseed grub-installer/
preseed grub-installer/
The installation fails with the error (from syslog):
Apr 19 22:12:13 grub-installer: info: Installing grub on '/dev/sdb /dev/sdc'
Apr 19 22:12:13 grub-installer: info: grub-install supports --no-floppy
Apr 19 22:12:13 grub-installer: info: Running chroot /target grub-install --no-floppy --force "/dev/sdb"
Apr 19 22:12:13 grub-installer: /usr/sbin/
Apr 19 22:12:13 grub-installer: /usr/sbin/
Apr 19 22:12:13 grub-installer: error: Running 'grub-install --no-floppy --force "/dev/sdb"' failed.
Looking at the state of the disks at that time shows that /dev/sdc is all correctly partitioned and /dev/sdc1 has the bios_grub flag set (parted shows the flag is set) BUT /dev/sdb1 does NOT have the bios_grub flag set!!!
So somehow the installer fails to set this flag on /dev/sdb1 but it does set it on /dev/sdc1.
As an experiment, when the error occurred, I went to the shell with Alt+F2, then did:
chroot /target /bin/bash
parted /dev/sdb
toggle 1 bios_grub
quit
Then went back to the installer (Alt+F1), then selected "Back" and then pressed "Enter" so that it repeated the step of trying to install grub. Grub then installed fine and the installation proceeded to completion and the system is now installed and working fine.
So clearly the only problem is that the bios_grub flag is not being set on the first disk in the raid setup.
This really needs to be fixed otherwise 10.04 LTS will not be very useful for people with large disks who want to use software raid and custom partitioning...
Thanks a lot in advance!
Best regards,
Anton
Changed in partman-auto (Ubuntu Lucid): | |
status: | In Progress → Fix Committed |
Forgot to say that this is on 64-bit Ubuntu (amd64) and that the installation is started using DHCP+PXE booting and the pxelinux. cfg/default entry which kicks off the installation is:
LABEL install installer/ amd64/linux ubuntu- installer/ amd64/initrd. gz ks=http:// bes.csi. cam.ac. uk/kickstart/ ks.cfg --
kernel ubuntu-
append vga=normal initrd=
Where the ks.cfg is the config file I have attached to this bug report.