Grub2 未检测到 btrfs 分区

Grub2 未检测到 btrfs 分区

我刚刚安装了 Xubuntu 以及基于 Arch 的发行版。问题是 Grub2 无法检测到上一个发行版的 (btrfs) 分区,所以我无法从中启动。我已经尝试过 update-grub2。

顺便说一句,在我安装 Xubuntu 之前,该 btrfs 分区可以从 Grub2 正常启动。

我能做些什么?

答案1

GRUB os-prober 在检测 btrfs @subvolumes 时出现问题,ubuntu-forums 上的“rick3332”给出了最简单的答案,让我可以在双启动 btrfs 操作系统安装(ubuntu16&18)上使用,每个操作系统都有自己的 grub。无需全面破解 os-prober 代码或进行非持久性手动 grub.cfg 编辑。只需在每个 btrfs 卷根中为 @/boot 和 @/etc 创建符号链接,然后在每个操作系统中运行“sudo update-grub2”。

#navigate to root of your current booted brtfs based OS
cd /
#create symlink for boot
ln -s @/boot boot
#create symlink for etc
ln -s @/etc etc

#mount the other btrfs volume with OS-install and navigate to its root
cd /mnt/exampleotherbtrfsvolume
#create symlink for boot
ln -s @/boot boot
#create symlink for etc
ln -s @/etc etc

#let grub detect btrfs based install volume
sudo update-grub2

#reboot to the other btrfs based OS (probably listed this time in grubmenu)
#let this grub detect the previously booted btrfs volume
sudo update-grub2

https://ubuntuforums.org/showthread.php?t=2369106&p=13677811#post13677811

相关内容