Bug#658214: Chainloader failed when Grub2 is installed on a partition

Lingfeng Xiong xionglingfeng at gmail.com
Wed Feb 1 05:04:02 UTC 2012


Package: grub2
Version: 1.98+20100804-14+squeeze1
Severity: normal
Tags: squeeze



I have three Linux installed in my computer, two Debian and one Fedora.
Grub of Debian on /dev/sdc1 is installed on MBR, it works great.
Grub of Fedora on /dev/sdc7 is installed on Fedora's root partition,
which can be chainloadered by the Grub in MBR with following commands:
root (hd0,gpt7)
chainloader +1
Grub of Debian on /dev/sdc6 is installed on it's partition. This grub cannot
be chainloadered by the one on MBR with commands of:
root (hd0,gpt6)
chainloader +1
The error reported by Grub on MBR is:
invalid signuature

I believe this is not a upstream bug coz the Grub distributed with Fedora
works great. As far as I know, Grub distributed with Debian can ONLY
be installed on MBR, or it woun't be chainloadered.
However, I don't know where the problem is at this time.

-- Package-specific info:

*********************** WARNING grub-setup left core.img in filesystem

*********************** BEGIN /proc/mounts
/dev/disk/by-uuid/30786545-2ea8-4f1f-9191-e226f8323f91 / ext4 rw,relatime,errors=remount-ro,barrier=1,data=ordered 0 0
/dev/sdc3 /tools ext4 rw,relatime,barrier=1,data=ordered 0 0
/dev/sdc9 /home reiserfs rw,relatime,user_xattr 0 0
*********************** END /proc/mounts

*********************** BEGIN /boot/grub/device.map
(hd0)	/dev/disk/by-id/ata-ST3500418AS_9VMAZDNX
(hd1)	/dev/disk/by-id/ata-WDC_WD6400AAKS-55A7B2_WD-WCASY9488009
(hd2)	/dev/disk/by-id/ata-ST3500418AS_9VMD6FPQ
(hd3)	/dev/disk/by-id/ata-ST3500418AS_5VMKG47Z
(hd4)	/dev/disk/by-id/ata-WDC_WD6401AALS-00L3B2_WD-WCASYA857198
*********************** END /boot/grub/device.map

*********************** BEGIN /boot/grub/grub.cfg
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
  load_env
fi
set default="0"
if [ "${prev_saved_entry}" ]; then
  set saved_entry="${prev_saved_entry}"
  save_env saved_entry
  set prev_saved_entry=
  save_env prev_saved_entry
  set boot_once=true
fi

function savedefault {
  if [ -z "${boot_once}" ]; then
    saved_entry="${chosen}"
    save_env saved_entry
  fi
}

function load_video {
  insmod vbe
  insmod vga
  insmod video_bochs
  insmod video_cirrus
}

insmod part_gpt
insmod ext2
set root='(hd2,gpt6)'
search --no-floppy --fs-uuid --set 30786545-2ea8-4f1f-9191-e226f8323f91
if loadfont /usr/share/grub/unicode.pf2 ; then
  set gfxmode=640x480
  load_video
  insmod gfxterm
fi
terminal_output gfxterm
insmod part_gpt
insmod ext2
set root='(hd2,gpt6)'
search --no-floppy --fs-uuid --set 30786545-2ea8-4f1f-9191-e226f8323f91
set locale_dir=($root)/boot/grub/locale
set lang=en
insmod gettext
set timeout=5
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
insmod part_gpt
insmod ext2
set root='(hd2,gpt6)'
search --no-floppy --fs-uuid --set 30786545-2ea8-4f1f-9191-e226f8323f91
insmod png
if background_image /usr/share/images/desktop-base/spacefun-grub.png; then
  set color_normal=light-gray/black
  set color_highlight=white/black
else
  set menu_color_normal=cyan/blue
  set menu_color_highlight=white/blue
fi
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry 'Debian GNU/Linux, with Linux 2.6.32-5-amd64' --class debian --class gnu-linux --class gnu --class os {
	insmod part_gpt
	insmod ext2
	set root='(hd2,gpt6)'
	search --no-floppy --fs-uuid --set 30786545-2ea8-4f1f-9191-e226f8323f91
	echo	'Loading Linux 2.6.32-5-amd64 ...'
	linux	/boot/vmlinuz-2.6.32-5-amd64 root=UUID=30786545-2ea8-4f1f-9191-e226f8323f91 ro  quiet
	echo	'Loading initial ramdisk ...'
	initrd	/boot/initrd.img-2.6.32-5-amd64
}
menuentry 'Debian GNU/Linux, with Linux 2.6.32-5-amd64 (recovery mode)' --class debian --class gnu-linux --class gnu --class os {
	insmod part_gpt
	insmod ext2
	set root='(hd2,gpt6)'
	search --no-floppy --fs-uuid --set 30786545-2ea8-4f1f-9191-e226f8323f91
	echo	'Loading Linux 2.6.32-5-amd64 ...'
	linux	/boot/vmlinuz-2.6.32-5-amd64 root=UUID=30786545-2ea8-4f1f-9191-e226f8323f91 ro single 
	echo	'Loading initial ramdisk ...'
	initrd	/boot/initrd.img-2.6.32-5-amd64
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows 7 (loader) (on /dev/sda1)" {
	insmod part_msdos
	insmod ntfs
	set root='(hd0,msdos1)'
	search --no-floppy --fs-uuid --set 443a11113a11021a
	chainloader +1
}
menuentry "Windows NT/2000/XP (on /dev/sda2)" {
	insmod part_msdos
	insmod ntfs
	set root='(hd0,msdos2)'
	search --no-floppy --fs-uuid --set fe4cee7a4cee2cd9
	drivemap -s (hd0) ${root}
	chainloader +1
}
menuentry "Mac OS X (32-bit) (on /dev/sdb3)" {
	insmod part_gpt
	insmod hfsplus
	set root='(hd1,gpt3)'
	search --no-floppy --fs-uuid --set 3aac65d969811477
        load_video
        set do_resume=0
        if [ /var/vm/sleepimage -nt10 / ]; then
           if xnu_resume /var/vm/sleepimage; then
             set do_resume=1
           fi
        fi
        if [ $do_resume = 0 ]; then
           xnu_uuid 3aac65d969811477 uuid
           if [ -f /Extra/DSDT.aml ]; then
              acpi -e /Extra/DSDT.aml
           fi
           xnu_kernel /mach_kernel boot-uuid=${uuid} rd=*uuid
           if [ /System/Library/Extensions.mkext -nt /System/Library/Extensions ]; then
              xnu_mkext /System/Library/Extensions.mkext
           else
              xnu_kextdir /System/Library/Extensions
           fi
           if [ -f /Extra/Extensions.mkext ]; then
              xnu_mkext /Extra/Extensions.mkext
           fi
           if [ -d /Extra/Extensions ]; then
              xnu_kextdir /Extra/Extensions
           fi
           if [ -f /Extra/devprop.bin ]; then
              xnu_devprop_load /Extra/devprop.bin
           fi
           if [ -f /Extra/splash.jpg ]; then
              insmod jpeg
              xnu_splash /Extra/splash.jpg
           fi
           if [ -f /Extra/splash.png ]; then
              insmod png
              xnu_splash /Extra/splash.png
           fi
           if [ -f /Extra/splash.tga ]; then
              insmod tga
              xnu_splash /Extra/splash.tga
           fi
        fi
}
menuentry "Mac OS X (64-bit) (on /dev/sdb3)" {
	insmod part_gpt
	insmod hfsplus
	set root='(hd1,gpt3)'
	search --no-floppy --fs-uuid --set 3aac65d969811477
        load_video
        set do_resume=0
        if [ /var/vm/sleepimage -nt10 / ]; then
           if xnu_resume /var/vm/sleepimage; then
             set do_resume=1
           fi
        fi
        if [ $do_resume = 0 ]; then
           xnu_uuid 3aac65d969811477 uuid
           if [ -f /Extra/DSDT.aml ]; then
              acpi -e /Extra/DSDT.aml
           fi
           xnu_kernel64 /mach_kernel boot-uuid=${uuid} rd=*uuid
           if [ /System/Library/Extensions.mkext -nt /System/Library/Extensions ]; then
              xnu_mkext /System/Library/Extensions.mkext
           else
              xnu_kextdir /System/Library/Extensions
           fi
           if [ -f /Extra/Extensions.mkext ]; then
              xnu_mkext /Extra/Extensions.mkext
           fi
           if [ -d /Extra/Extensions ]; then
              xnu_kextdir /Extra/Extensions
           fi
           if [ -f /Extra/devprop.bin ]; then
              xnu_devprop_load /Extra/devprop.bin
           fi
           if [ -f /Extra/splash.jpg ]; then
              insmod jpeg
              xnu_splash /Extra/splash.jpg
           fi
           if [ -f /Extra/splash.png ]; then
              insmod png
              xnu_splash /Extra/splash.png
           fi
           if [ -f /Extra/splash.tga ]; then
              insmod tga
              xnu_splash /Extra/splash.tga
           fi
        fi
}
menuentry "Mac OS X (32-bit) (on /dev/sdb7)" {
	insmod part_gpt
	insmod hfsplus
	set root='(hd1,gpt7)'
	search --no-floppy --fs-uuid --set 1bbb49ccba2174bc
        load_video
        set do_resume=0
        if [ /var/vm/sleepimage -nt10 / ]; then
           if xnu_resume /var/vm/sleepimage; then
             set do_resume=1
           fi
        fi
        if [ $do_resume = 0 ]; then
           xnu_uuid 1bbb49ccba2174bc uuid
           if [ -f /Extra/DSDT.aml ]; then
              acpi -e /Extra/DSDT.aml
           fi
           xnu_kernel /mach_kernel boot-uuid=${uuid} rd=*uuid
           if [ /System/Library/Extensions.mkext -nt /System/Library/Extensions ]; then
              xnu_mkext /System/Library/Extensions.mkext
           else
              xnu_kextdir /System/Library/Extensions
           fi
           if [ -f /Extra/Extensions.mkext ]; then
              xnu_mkext /Extra/Extensions.mkext
           fi
           if [ -d /Extra/Extensions ]; then
              xnu_kextdir /Extra/Extensions
           fi
           if [ -f /Extra/devprop.bin ]; then
              xnu_devprop_load /Extra/devprop.bin
           fi
           if [ -f /Extra/splash.jpg ]; then
              insmod jpeg
              xnu_splash /Extra/splash.jpg
           fi
           if [ -f /Extra/splash.png ]; then
              insmod png
              xnu_splash /Extra/splash.png
           fi
           if [ -f /Extra/splash.tga ]; then
              insmod tga
              xnu_splash /Extra/splash.tga
           fi
        fi
}
menuentry "Mac OS X (64-bit) (on /dev/sdb7)" {
	insmod part_gpt
	insmod hfsplus
	set root='(hd1,gpt7)'
	search --no-floppy --fs-uuid --set 1bbb49ccba2174bc
        load_video
        set do_resume=0
        if [ /var/vm/sleepimage -nt10 / ]; then
           if xnu_resume /var/vm/sleepimage; then
             set do_resume=1
           fi
        fi
        if [ $do_resume = 0 ]; then
           xnu_uuid 1bbb49ccba2174bc uuid
           if [ -f /Extra/DSDT.aml ]; then
              acpi -e /Extra/DSDT.aml
           fi
           xnu_kernel64 /mach_kernel boot-uuid=${uuid} rd=*uuid
           if [ /System/Library/Extensions.mkext -nt /System/Library/Extensions ]; then
              xnu_mkext /System/Library/Extensions.mkext
           else
              xnu_kextdir /System/Library/Extensions
           fi
           if [ -f /Extra/Extensions.mkext ]; then
              xnu_mkext /Extra/Extensions.mkext
           fi
           if [ -d /Extra/Extensions ]; then
              xnu_kextdir /Extra/Extensions
           fi
           if [ -f /Extra/devprop.bin ]; then
              xnu_devprop_load /Extra/devprop.bin
           fi
           if [ -f /Extra/splash.jpg ]; then
              insmod jpeg
              xnu_splash /Extra/splash.jpg
           fi
           if [ -f /Extra/splash.png ]; then
              insmod png
              xnu_splash /Extra/splash.png
           fi
           if [ -f /Extra/splash.tga ]; then
              insmod tga
              xnu_splash /Extra/splash.tga
           fi
        fi
}
menuentry "Debian GNU/Linux, with Linux 2.6.32-5-amd64 (on /dev/sdc1)" {
	insmod part_gpt
	insmod ext2
	set root='(hd2,gpt1)'
	search --no-floppy --fs-uuid --set 83c39e7b-7dd2-4b72-8906-2d145df10d9c
	linux /boot/vmlinuz-2.6.32-5-amd64 root=UUID=83c39e7b-7dd2-4b72-8906-2d145df10d9c ro quiet
	initrd /boot/initrd.img-2.6.32-5-amd64
}
menuentry "Debian GNU/Linux, with Linux 2.6.32-5-amd64 (recovery mode) (on /dev/sdc1)" {
	insmod part_gpt
	insmod ext2
	set root='(hd2,gpt1)'
	search --no-floppy --fs-uuid --set 83c39e7b-7dd2-4b72-8906-2d145df10d9c
	linux /boot/vmlinuz-2.6.32-5-amd64 root=UUID=83c39e7b-7dd2-4b72-8906-2d145df10d9c ro single
	initrd /boot/initrd.img-2.6.32-5-amd64
}
menuentry "Fedora (3.2.2-1.fc16.x86_64) (on /dev/sdc7)" {
	insmod part_gpt
	insmod ext2
	set root='(hd2,gpt7)'
	search --no-floppy --fs-uuid --set b7334858-8e6d-441b-8daa-8b3a55f89d16
	linux /boot/vmlinuz-3.2.2-1.fc16.x86_64 ro root=UUID=b7334858-8e6d-441b-8daa-8b3a55f89d16 rd_NO_LUKS rd_NO_LVM rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYTABLE=us rhgb quiet nouveau.modeset=0 rd.driver.blacklist=nouveau
	initrd /boot/initramfs-3.2.2-1.fc16.x86_64.img
}
menuentry "Fedora (3.1.9-1.fc16.x86_64) (on /dev/sdc7)" {
	insmod part_gpt
	insmod ext2
	set root='(hd2,gpt7)'
	search --no-floppy --fs-uuid --set b7334858-8e6d-441b-8daa-8b3a55f89d16
	linux /boot/vmlinuz-3.1.9-1.fc16.x86_64 ro root=UUID=b7334858-8e6d-441b-8daa-8b3a55f89d16 rd_NO_LUKS rd_NO_LVM rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYTABLE=us rhgb quiet nouveau.modeset=0 rd.driver.blacklist=nouveau
	initrd /boot/initramfs-3.1.9-1.fc16.x86_64.img
}
menuentry "Fedora (3.1.7-1.fc16.x86_64) (on /dev/sdc7)" {
	insmod part_gpt
	insmod ext2
	set root='(hd2,gpt7)'
	search --no-floppy --fs-uuid --set b7334858-8e6d-441b-8daa-8b3a55f89d16
	linux /boot/vmlinuz-3.1.7-1.fc16.x86_64 ro root=UUID=b7334858-8e6d-441b-8daa-8b3a55f89d16 rd_NO_LUKS rd_NO_LVM rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYTABLE=us rhgb quiet nouveau.modeset=0 rd.driver.blacklist=nouveau
	initrd /boot/initramfs-3.1.7-1.fc16.x86_64.img
}
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###

### BEGIN /etc/grub.d/41_custom ###
if [ -f  $prefix/custom.cfg ]; then
  source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###
*********************** END /boot/grub/grub.cfg

-- System Information:
Debian Release: 6.0.4
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'proposed-updates'), (500, 'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-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/dash

Versions of packages grub2 depends on:
ii  grub-pc        1.98+20100804-14+squeeze1 GRand Unified Bootloader, version 

grub2 recommends no packages.

grub2 suggests no packages.

-- no debconf information





More information about the Pkg-grub-devel mailing list