What are the known supported (and unsupported) features for the GRUB2 lvm module in Debian 9? E.g. does it support the current metadata format "lvm2"?
Is there some extra command or configuration required to access LVM logical volumes from GRUB, even after loading the GRUB lvm
module?
GRUB appears to support MD-raid, but what about when LVM is running on top of MD-raid, does it affect the above questions somehow? Is grub2-mkconfig
expected to support /boot
on MD+LVM?
Context
I need to migrate files from one existing disk into the RAID, so I'm not using the installer to set things up. This is for Debian Stretch. The general idea is
- copy your existing system to a degraded RAID on the new disk
- boot the RAID system
- very carefully double-check and then have the RAID swallow the old disk.
I'm aware this isn't necessarily the most sensible of ideas.
I'm looking at booting from LVM on MD-raid. I won't bother faffing with /boot as a separate MD-raid partition, if I don't need to. It looked like this is what the Debian installer was being used to do in https://wiki.debian.org/DebianInstaller/SoftwareRaidRoot
I created an LV on top of MD-raid, and copied the root filesystem to it. But unlike the pure MD-raid setup described on the RAID wiki, grub-mkconfig
did not find the new Linux instance.
I booted to the GRUB prompt of the original Linux instance, to see what it could do. I can load the part_gpt
, mdraid1x
, and lvm
modules. There is no lvm2
module. This successfully found devices for my GPT partitions, and the MD device (md/linux)
I had created. But it did not find any of the LVM devices I had created, which should have looked like (lvm/vg_linux/lv_root)
.
The probe
command does not work at all on either (hd1,gpt1)
or (md/linux)
; it just says error: unknown filesystem
. So it's not capable of identifying the MD-raid, let alone the LVM stuff, even though GRUB is already accessing the MD-raid.
update-grub
and it seems to be able to figure out what modules to load. Is there something I'm missing? – Faheem Mitha Sep 04 '17 at 14:55/boot
, which makes for a sub-optimally complicated process IMO). – sourcejedi Sep 04 '17 at 19:17os-prober
is a Recommends forgrub-common
, so you really should have had it installed. (Brought to my attention byaptitide why
). – Faheem Mitha Sep 04 '17 at 21:19