ubiquity grub-install fails with /boot on RAID, ubiquity does not install mdadm, workaround included

Bug #1852041 reported by Jim At Your Service
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ubiquity (Ubuntu)
New
Undecided
Unassigned

Bug Description

With Ubuntu 18.04

Ubiquity installer should install mdadm before running grub-install if /boot is on a RAID disk.

There have been multiple bug reports filed over the years against grub-installer.
The grub-installer is fine. To support /boot on RAID, mdadm should be pre-installed.

Various recipes explain to work-around the issue just drop to a shell after the installer complains, and chroot to the target, and install mdadm, then do grub-install. Not so easy.

In my case, I have a ubiquty/success_command that has to run, and the workaround requires
allowing ubiquity to fail, and so the success_command never happens, nor does any final cleanup.

The workaround I used was to to hack on the live-CD, which must be done after boot,
or in my case remains persistent because I made a persistent live-CD using mkusb.

vi /usr/share/grub-installer/grub-installer
        # near line 647 change from
        apt-install $grub_package || exit_code=$?
        # change to
        # 13.0.6.17.15-t10 jimays Hack to make sure mdadm is installed so grub-install will succeed with RAID.
        apt-install -y mdadm $grub_package || exit_code=$?

And then ubiquity succeeds and grub installs with /boot on /dev/md1.
I am not sure where the actual proper place to install mdadm is
or what the proper test would be to see if it is actually needed.

affects: grub-installer (Ubuntu) → ubiquity (Ubuntu)
summary: ubiquity grub-install fails with /boot on RAID, ubiquity does not
- install mdadm
+ install mdadm, workaround included
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.