'grub-install --no-floppy /dev/md0' fails

Bug #462171 reported by Olleg Samoylov on 2009-10-27
30
This bug affects 7 people
Affects Status Importance Assigned to Milestone
grub-installer (Ubuntu)
Undecided
Unassigned
grub2 (Ubuntu)
Undecided
Unassigned

Bug Description

Binary package hint: grub-installer

1.97~beta4-1ubuntu3 from karmic-updates lead to errors on installation on software raid and to unbootable system.

Oct 27 10:37:35 in-target: Настраивается пакет grub-common (1.97~beta4-1ubuntu3) ...
Oct 27 10:37:35 in-target:
Oct 27 10:37:35 in-target: Настраивается пакет grub-pc (1.97~beta4-1ubuntu3) ...
Oct 27 10:37:36 debconf: Obsolete command TITLE Настраивается пакет grub-pc called
Oct 27 10:37:36 in-target:
Oct 27 10:37:36 in-target: Creating config file /etc/default/grub with new version
Oct 27 10:37:36 in-target:
Oct 27 10:37:36 in-target: Обрабатываются триггеры для libc-bin ...
Oct 27 10:37:36 in-target: ldconfig deferred processing now taking place
Oct 27 10:37:37 anna-install: Installing ext2-modules
Oct 27 10:37:37 os-prober: unknown udeb ext2-modules
Oct 27 10:37:37 anna-install: Installing ext3-modules
Oct 27 10:37:37 os-prober: unknown udeb ext3-modules
Oct 27 10:37:37 anna-install: Installing ext4-modules
Oct 27 10:37:37 os-prober: unknown udeb ext4-modules
Oct 27 10:37:37 anna-install: Installing reiserfs-modules
Oct 27 10:37:37 anna-install: Installing xfs-modules
Oct 27 10:37:37 anna-install: Installing jfs-modules
Oct 27 10:37:37 anna-install: Installing msdos-modules
Oct 27 10:37:37 os-prober: unknown udeb msdos-modules
Oct 27 10:37:37 anna-install: Installing vfat-modules
Oct 27 10:37:37 os-prober: unknown udeb vfat-modules
Oct 27 10:37:37 anna-install: Installing ntfs-modules
Oct 27 10:37:37 anna-install: Installing minix-modules
Oct 27 10:37:37 os-prober: unknown udeb minix-modules
Oct 27 10:37:37 anna-install: Installing hfs-modules
Oct 27 10:37:37 anna-install: Installing hfsplus-modules
Oct 27 10:37:37 os-prober: unknown udeb hfsplus-modules
Oct 27 10:37:37 anna-install: Installing qnx4-modules
Oct 27 10:37:37 os-prober: unknown udeb qnx4-modules
Oct 27 10:37:37 anna-install: Installing ufs-modules
Oct 27 10:37:37 os-prober: unknown udeb ufs-modules
Oct 27 10:37:37 anna-install: Installing fs-core-modules
Oct 27 10:37:37 anna-install: Installing fs-secondary-modules
Oct 27 10:37:37 os-prober: File descriptor 3 left open
Oct 27 10:37:37 os-prober: File descriptor 4 left open
Oct 27 10:37:37 os-prober: File descriptor 5 left open
Oct 27 10:37:37 os-prober: File descriptor 6 left open
Oct 27 10:37:37 os-prober: debug: running /usr/lib/os-probes/50mounted-tests on /dev/sda1
Oct 27 10:37:37 50mounted-tests: debug: /dev/sda1 is a swap partition; skipping
Oct 27 10:37:37 os-prober: debug: os detected by /usr/lib/os-probes/50mounted-tests
Oct 27 10:37:37 os-prober: debug: running /usr/lib/os-probes/50mounted-tests on /dev/sda2
Oct 27 10:37:37 os-prober: debug: running /usr/lib/os-probes/50mounted-tests on /dev/sdb1
Oct 27 10:37:37 50mounted-tests: debug: /dev/sdb1 is a swap partition; skipping
Oct 27 10:37:37 os-prober: debug: os detected by /usr/lib/os-probes/50mounted-tests
Oct 27 10:37:37 os-prober: debug: running /usr/lib/os-probes/50mounted-tests on /dev/sdb2
Oct 27 10:37:37 grub-installer: info: Installing grub on '/dev/md0'
Oct 27 10:37:37 grub-installer: info: grub-install supports --no-floppy
Oct 27 10:37:37 grub-installer: info: Running chroot /target grub-install --no-floppy "/dev/md0"
Oct 27 10:37:38 grub-installer: grub-setup: warn: Attempting to install GRUB to a partition instead of the MBR. This is a BAD idea.
Oct 27 10:37:38 grub-installer: grub-setup: error: Embedding is not possible, but this is required when the root device is on a RAID array or LVM volume.
Oct 27 10:37:38 grub-installer: error: Running 'grub-install --no-floppy "/dev/md0"' failed.
Oct 27 10:37:48 main-menu[420]: (process:12827): File descriptor 3 left open
Oct 27 10:37:48 main-menu[420]: (process:12827): File descriptor 4 left open
Oct 27 10:37:48 main-menu[420]: (process:12827): File descriptor 5 left open
Oct 27 10:37:48 main-menu[420]: (process:12827): File descriptor 6 left open
Oct 27 10:37:48 main-menu[420]: (process:12827): Volume group "md0" not found

1.97~beta4-1ubuntu2 from the CD works fine. Workaround, manually downgrade grub-pc or don't setup network on install (if setup network then grub-pc is updated quietly and lead to unbootable system).

ceg (ceg) wrote :

Confirming:

# grub-install /dev/md1
grub-setup: warn: Attempting to install GRUB to a partition instead of the MBR. This is a BAD idea.
grub-setup: error: Embedding is not possible, but this is required when the root device is on a RAID array or LVM volume.

# cat /proc/mdstat
Personalities : [raid1] [linear] [multipath] [raid0] [raid6] [raid5] [raid4] [raid10]
md1 : active raid1 sda1[0]
      184640 blocks [2/1] [U_]

The is 7 MB unused space available before sda1. (I am currently booting from sdb2 since booting from md1 is not possible.)

Changed in grub2 (Ubuntu):
status: New → Confirmed
ceg (ceg) wrote :

# fdisk -l /dev/sda

Platte /dev/sda: 82.3 GByte, 82348277760 Byte
255 Köpfe, 63 Sektoren/Spuren, 10011 Zylinder
Einheiten = Zylinder von 16065 × 512 = 8225280 Bytes
Disk identifier: 0x0009d720

   Gerät boot. Anfang Ende Blöcke Id System
/dev/sda1 2 24 184747+ fd Linux raid autodetect
/dev/sda2 25 10011 80220577+ fd Linux raid autodetect

ceg (ceg) on 2010-01-09
summary: - error: Running 'grub-install --no-floppy "/dev/md0"' failed.
+ 'grub-install --no-floppy /dev/md0' fails
andrew bezella (abezella) wrote :

this remains a problem in 10.04.1 and likely in maverick as well:

# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 10.04.1 LTS
Release: 10.04
Codename: lucid
# grub-install --version
grub-install (GNU GRUB 1.98-1ubuntu5)
# grub-install --no-floppy "(md0)"
/usr/sbin/grub-setup: warn: Attempting to install GRUB to a partition instead of the MBR. This is a BAD idea..
/usr/sbin/grub-setup: error: embedding is not possible, but this is required when the root device is on a RAID array or LVM volume.

i also tested 1.98-1ubuntu7 from lucid-updates and 1.98+20100804-5ubuntu3 with the same results. this appears to be an ubuntu-specific issue introduced between 1.97~beta4-1ubuntu2 and 1.97~beta4-1ubuntu3 (as mentioned in the original report). on a whim i tried the straight-up debian version of the package (1.98+20100804-5) which installed to md0 with "No error reported".

the workaround from http://ubuntu-ky.ubuntuforums.org/showthread.php?p=9638149 was helpful.

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in grub-installer (Ubuntu):
status: New → Confirmed
Olleg Samoylov (olleg) wrote :

After two years this bug is confirmed. :) Incredible. :)

andrew bezella (abezella) wrote :

still unresolved in 12.04:
# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 12.04 LTS
Release: 12.04
Codename: precise
# grub-install --version
grub-install (GRUB) 1.99-21ubuntu3
# grub-install --no-floppy "/dev/md0"
/usr/sbin/grub-setup: warn: Attempting to install GRUB to a partitionless disk or to a partition. This is a BAD idea..
/usr/sbin/grub-setup: warn: Embedding is not possible. GRUB can only be installed in this setup by using blocklists. However, blocklists are UNRELIABLE and their use is discouraged..
/usr/sbin/grub-setup: error: will not proceed with blocklists.

Phillip Susi (psusi) wrote :

You need to install grub to the underlying physical disks ( /dev/sda, /dev/sdb, etc ), not the raid array.

Changed in grub2 (Ubuntu):
status: Confirmed → Invalid
Changed in grub-installer (Ubuntu):
status: Confirmed → Invalid
PkLab.net (pklab) wrote :

please note that the server guide for 14.04 (installation guide https://help.ubuntu.com/14.04/serverguide/advanced-installation.html) states:

  sudo grub-install /dev/md0

and error still persist
# grub-install --version
grub-install (GRUB) 2.02~beta2-9ubuntu1

# grub-install /dev/md0
Installing for i386-pc platform.
grub-install: warning: File system `ext2' doesn't support embedding.
grub-install: warning: Embedding is not possible. GRUB can only be installed in this setup by using blocklists. However, blocklists are UNRELIABLE and their use is discouraged..
grub-install: error: will not proceed with blocklists.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers