[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#688336: update-grub finds only one system on btrfs volume



Package: os-prober
Version: 1.55

Grub and the working environment are installed on a btrfs subvolume.
update-grub does not find any other linux systems on different
subvolumens (same btrfs filesystem).
To reproduce on debian with btrfs-tools:
Have a spare device, say /dev/sdc1
mkfs.btrfs /dev/sdc1
mount /dev/sdc1 /mnt
btrfs subvol create /mnt/first
debootstrap unstable /mnt/first
mount --bind /dev /mnt/first/dev
mount --bind /proc /mnt/first/proc
mount --bind /sys /mnt/first/sys
chroot /mnt/first
apt-get install linux-image-3.2*
apt-get install grub2

At this point it correctly detects a single system on btrfs. Now
exit
btrfs subvol snapshot /mnt/first /mnt/second

This creates two distinct systems, yet
chroot /mnt/first
update-grub

Yields only a single result on btrfs volume. We can boot to the other
one by changing /boot/grub/grub.cfg (s/first/second in
rootflags=subvol=X) but it should detect different systems
automatically. Also does not work when installing two distinct systems
instead of cloning one as demonstrated here.


Reply to: