For When You Can't Have The Real Thing
[ start | index | login ]
start > Linux > Grub won't install to raid-1

Grub won't install to raid-1

Created by dave. Last edited by dave, 13 years and 106 days ago. Viewed 5,750 times. #1
[edit] [rdf]

Grub won't install to raid-1 disks

Description of problem: Two SCSI drives, /dev/sda and /dev/sdb. RAID-1 used to make mirrored / and /boot. LILO handles this configuration with root=/dev/md0

I tried grub-install with each of /dev/md0, /dev/md1, /dev/sda, and /dev/sdb. Each reported that /dev/md? does not have any corresponding BIOS drive, and failed to overwrite the MBR. A containing fd0, sda, and sdb was built but md0 and md1 were not mentioned.


I was incurring the same problems, but was finally able to get grub to install by doing the following:

# grub --batch
Probing devices to guess BIOS drives. This may take a long time.

GRUB version 0.93 (640K lower / 3072K upper memory)

[ Minimal BASH-like line editing is supported. For the first word, TAB lists possible command completions. Anywhere else TAB lists the possible completions of a device/filename.] grub> root (hd0,0) root (hd0,0) Filesystem type is ext2fs, partition type 0xfd grub> setup (hd0) setup (hd0) Checking if "/boot/grub/stage1" exists… no Checking if "/grub/stage1" exists… yes Checking if "/grub/stage2" exists… yes Checking if "/grub/e2fs_stage1_5" exists… yes Running "embed /grub/e2fs_stage1_5 (hd0)"… 16 sectors are embedded. succeeded Running "install /grub/stage1 (hd0) (hd0)1+16 p (hd0,0)/grub/stage2 /grub/grub.conf"… succeeded Done.

Contents of /boot/grub/ (fd0) /dev/fd0 (hd0) /dev/hda

df listing:

Filesystem 1K-blocks Used Available Use% Mounted on /dev/md1 10080428 1361604 8206760 15% / /dev/md0 2063440 38036 1920588 2% /boot /dev/md2 62712132 35536 59490916 1% /local none 111476 0 111476 0% /dev/shm

My thoughts are that this bug may not get much attention being listed as a "7.2" bug, when in fact it's still happening with even the latest rawhide build of grub (0.93-4). It is, afterall, just a shell script.

no comments | post comment
This is a collection of techical information, much of it learned the hard way. Consider it a lab book or a /info directory. I doubt much of it will be of use to anyone else.

Useful: | Copyright 2000-2002 Matthias L. Jugel and Stephan J. Schmidt