[Bug 1238347] Re: Invalid grub.cfg generated if root on RAID1 btrfs
Wojciech Niziński
1238347 at bugs.launchpad.net
Tue Feb 7 11:21:49 UTC 2017
Problem still valid for version 2.02~beta2-36ubuntu11.
I'm using multi-device BTRFS as root file system.
Configuration generated by grub-install adds wrong kernel argument with newline:
linux /vmlinuz-4.4.0-62-generic root=/dev/mapper/sth--proc-root
/dev/mapper/sth--proc2-root ro rootflags=subvol=@ panic=30
but it should generate UUID (UUIDs are not disabled in my config):
linux /vmlinuz-4.4.0-62-generic root=UUID=ed730508-753e-4a7f-ac1e-bf8646f7bd63 ro rootflags=subvol=@ panic=30
because of
# blkid
/dev/mapper/sth--proc2-root: LABEL="btrfs_root" UUID="ed730508-753e-4a7f-ac1e-bf8646f7bd63" UUID_SUB="3508e65d-22af-43c3-9fe6-446f63e203cc" TYPE="btrfs"
/dev/mapper/sth--proc-root: LABEL="btrfs_root" UUID="ed730508-753e-4a7f-ac1e-bf8646f7bd63" UUID_SUB="27c2248f-4072-4e3a-b782-99161460fcb2" TYPE="btrfs"
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to grub2 in Ubuntu.
https://bugs.launchpad.net/bugs/1238347
Title:
Invalid grub.cfg generated if root on RAID1 btrfs
Status in grub2 package in Ubuntu:
Confirmed
Bug description:
If Ubuntu Saucy is installed onto a btrfs root device, which is
configured to be a RAID1 mirror (or probably other configurations)
then the grub.cfg is generated with invalid entries.
This is because /etc/grub.d/10_linux gets *both* device names from
btrfs, with a newline between them, and then just sticks that
everywhere in the config file where it was expecting just one device.
The newline in the middle prematurely truncates lines and then starts
new invalid ones.
To reproduce, create your btrfs device something like this during install:
mkfs.btrfs -d raid1 -m raid1 /dev/sda1 /dev/sdb1
ProblemType: Bug
DistroRelease: Ubuntu 13.10
Package: grub-common 2.00-19ubuntu1 [modified: usr/sbin/grub-mkconfig usr/share/grub/grub-mkconfig_lib]
ProcVersionSignature: Ubuntu 3.11.0-11.17-generic 3.11.3
Uname: Linux 3.11.0-11-generic x86_64
NonfreeKernelModules: nvidia
ApportVersion: 2.12.5-0ubuntu1
Architecture: amd64
Date: Fri Oct 11 12:21:17 2013
InstallationDate: Installed on 2013-10-09 (1 days ago)
InstallationMedia: Ubuntu 13.10 "Saucy Salamander" - Beta amd64 (20130925.1)
MarkForUpload: True
SourcePackage: grub2
UpgradeStatus: No upgrade log present (probably fresh install)
modified.conffile..etc.grub.d.10.linux: [modified]
mtime.conffile..etc.grub.d.10.linux: 2013-10-11T12:18:01.364605
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1238347/+subscriptions
More information about the foundations-bugs
mailing list