Bug#494383: grub-pc: Grub2 cannot find LVM volume groups with a dash (-) in the name
root
s.marechal at jejik.com
Fri Aug 8 20:23:37 UTC 2008
Package: grub-pc
Version: 1.96+20080724-5
Severity: important
Grub2 does not work on LVM if the LVM volume group has a dash in the
name. I have tried this on a clean install of Debian Lenny using the
Debian Installer beta2 netinst for amd64. I have one hard disk which
is one big PV for LVM:
* volume group "linux-vg" (or "linuxvg")
* volume "boot"
* volume "root"
* volume "swap"
Because I have /boot on LVM, D-I installed Lilo for me and I installed
grub2 by hand:
# aptitude install grub-pc
Then I try to install it:
# grub-install /dev/sda
grub-probe: error: Unknown device linux--vg-boot
Autodetection of a file system module failed
Please specify the module with the option "--modules" explicitly
So, I do what it says:
# grub-install --modules="ext2 pc lvm" /dev/sda
grub-probe: error: Unknown device linux--vg-boot
grub-setup: error: Unknown device linux--vg-boot
However, when I install Lenny in the exact same way, only I name
the volume group "linuxvg" instead of "linux-vg" then it all
works just fine:
# grub-install /dev/sda
# update-grub
<output snipped>
# reboot
Welcome to Grub!
I have tried various other volume group names, both with and
without a dash in them. When the name contains a dash, grub2 fails.
When the name does not contain a dash, grub2 works.
-- Package-specific info:
*********************** BEGIN /proc/mounts
/dev/mapper/linuxvg-root / ext3 rw,errors=remount-ro,data=ordered 0 0
/dev/mapper/linuxvg-root /dev/.static/dev ext3 rw,errors=remount-ro,data=ordered 0 0
/dev/mapper/linuxvg-boot /boot ext3 rw,errors=continue,data=ordered 0 0
*********************** END /proc/mounts
*********************** BEGIN /boot/grub/device.map
(hd0) /dev/sda
*********************** END /boot/grub/device.map
*********************** BEGIN /boot/grub/grub.cfg
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/update-grub using templates
# from /etc/grub.d and settings from /etc/default/grub
#
### BEGIN /etc/grub.d/00_header ###
set default=0
set timeout=5
insmod lvm
set root=(linuxvg-root)
search --fs-uuid --set 07bbd91c-a0a9-4d9a-b90b-28f093798fca
if font /usr/share/grub/ascii.pff ; then
set gfxmode=640x480
insmod gfxterm
insmod vbe
terminal gfxterm
fi
### END /etc/grub.d/00_header ###
### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=cyan/blue
set menu_color_highlight=white/blue
### END /etc/grub.d/05_debian_theme ###
### BEGIN /etc/grub.d/10_hurd ###
### END /etc/grub.d/10_hurd ###
### BEGIN /etc/grub.d/10_linux ###
insmod lvm
set root=(linuxvg-boot)
search --fs-uuid --set b04ccca6-97b5-4387-98d4-b5edb67aedc3
menuentry "Debian GNU/Linux, linux 2.6.25-2-amd64" {
linux /vmlinuz-2.6.25-2-amd64 root=/dev/mapper/linuxvg-root ro
initrd /initrd.img-2.6.25-2-amd64
}
menuentry "Debian GNU/Linux, linux 2.6.25-2-amd64 (single-user mode)" {
linux /vmlinuz-2.6.25-2-amd64 root=/dev/mapper/linuxvg-root ro single
initrd /initrd.img-2.6.25-2-amd64
}
menuentry "Debian GNU/Linux, linux 2.6.24-1-amd64" {
linux /vmlinuz-2.6.24-1-amd64 root=/dev/mapper/linuxvg-root ro
initrd /initrd.img-2.6.24-1-amd64
}
menuentry "Debian GNU/Linux, linux 2.6.24-1-amd64 (single-user mode)" {
linux /vmlinuz-2.6.24-1-amd64 root=/dev/mapper/linuxvg-root ro single
initrd /initrd.img-2.6.24-1-amd64
}
### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/30_os-prober ###
### END /etc/grub.d/30_os-prober ###
### BEGIN /etc/grub.d/40_custom ###
# This file is an example on how to add custom entries
### END /etc/grub.d/40_custom ###
*********************** END /boot/grub/grub.cfg
-- System Information:
Debian Release: lenny/sid
APT prefers testing
APT policy: (500, 'testing')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.25-2-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
Versions of packages grub-pc depends on:
ii debconf [debconf-2.0] 1.5.22 Debian configuration management sy
ii grub-common 1.96+20080724-5 GRand Unified Bootloader, version
ii libc6 2.7-10 GNU C Library: Shared libraries
ii liblzo2-2 2.03-1 data compression library
ii libncurses5 5.6+20080713-1 shared libraries for terminal hand
grub-pc recommends no packages.
Versions of packages grub-pc suggests:
pn desktop-base <none> (no description available)
pn os-prober <none> (no description available)
-- debconf information:
grub-pc/linux_cmdline: fillme
grub-pc/chainload_from_menu.lst: true
More information about the Pkg-grub-devel
mailing list