Re: problem with grub
2008-05-15 17:02+0200 Gilles Guiot:
my server has two raid1 arrays, each with two disks, for a total of
four hd. sda1 relates to the biggest partion on the first array (sda)
and sdb1 relates to the only partition on the second raid array. point
is this sdb1 is "in lvm" so to speak, ie there is an lv using all of
2008-05-15 16:43+0200 hh.eu:
This is an installed and working server. Because we needed more space
for backuppc, the initial plan was to create an lvm on the second raid
array, boot to it and see if it worked, if so extend it by
incorporating the first raid array.
I don't quite understand why you only create LVM on sdb, not on sda,
and what you mean by "copying the filesystem from sda to sdb".
I am using software RAID, which gives me device names such as md0 and
the RAID arrays rather than sda and sdb, so are you using some sort of
hardware RAID (either with a real hardware RAID controller or 'fake
RAID' using the embedded controller on the motherboard)?
Anyway, if I understand you correctly, you have two partitions on the
set and just one partition (with LVM) on the new RAID set. The problem is
that (legacy) GRUB cannot deal with LVM directly. GRUB can understand RAID,
but not LVM. That's why people usually have a small RAID1 set on two disks
that contains just a partition on each disk for /boot, and another larger
RAID1 set on the same two disks that is entirely filled with LVM. That's
I was talking about:
You probably mean you have two partitions on disks sda and sdb, one
partition and a larger partition. Then you put the two small partitions
together in RAID1 and use it for /boot. You also put the two larger
together into another RAID1 array and use this for LVM.
In other words: You need two partitions on the new RAID set, too. The
the /boot partitions can be quite small, I chose 512 MB which should be
more than enough. (I didn't want to make it smaller because hard disk
cheap nowadays and making it bigger isn't so convenient because it's not on
I typed the first grub to enter the grub command, omitted to specifiy
it . Apologies.
when i type grub> root (sdb,0) , i get the message : syntax error near
unexpected token '('.
Could someone tell me what's my mistake and how to do it properly ?
Do you type "grub> root (sdb,0)" (without the "") all in one line? If
have misunderstood the instructions! You first need to type "grub",
enter, this will get you to the GRUB command, i.e. you will see a
prompt of "grub>" at the left. Only then you have to enter "root
all the other commands (each followed by pressing enter and without
I was asking because the error message seems very much like an error
from your normal shell, e.g. bash, which you shouldn't get from the GRUB
shell. (I am not in front of a Debian system so I can't test...)
You also need to specify the hard disk name/number in GRUB notation
something like hd0 or hd1, even for SCSI disks), not in the normal
i.e. "root (sdb,0)" doesn't work.
Unfortunately, GRUB uses some sort of guessing to map device names (e.g.
<--> hd0, sda <--> hd1) which is not very reliable. See a recent post
for tips and details to find out about the mapping:
Did you read the manual
Grub does tab completion so if you type root (<tab> it should give you a
list of the available drives as grub sees them. The file
/boot/grub/device.map shows how these translate to real hard drives.