Mailinglist Archive: opensuse (2224 mails)

< Previous Next >
Re: [opensuse] LILO/Grub Problem
  • From: Darryl Gregorash <raven@xxxxxxxxxxxxx>
  • Date: Mon, 05 Feb 2007 00:48:29 -0600
  • Message-id: <45C6D33D.5040707@xxxxxxxxxxxxx>
On 2007-02-04 16:19, Bob S wrote:
> On Sunday 04 February 2007 02:00, Darryl Gregorash wrote:
>
>> <snip>
>> "Root" in grub most certainly is the location of the kernel, ie. of
>> /boot. I assume the (hd1,0) is correct. Using that method to specify the
>> kernel and initrd locations, the "root" command is quite unnecessary.
>>
>>
> Ummmm...Don't quite understand what you are saying. Would you please explain
> more? Thanks
What is specified in the "root" command of a grub menu item has nothing
to do with what gets mounted as /. It is the location of /boot. The
partition that gets mounted as / goes into the kernel "root=" parameter.

Thus, if you have /dev/hdb2 (in grub, that becomes (hd1,1)) mounted as
/boot and /dev/hdb1 mounted as /, the proper grub commands are:

root (hd1,1)
kernel /vmlinuz root=/dev/hdb1 ....
initrd /initrd

In essence, the grub "root" command is saying, "this is the default
device for unresolved device references."

You may dispense with the root command, at least in some versions of
grub (such as the one distributed with 9.3), provided that all device
references are fully resolved:

kernel (hd1,1)/vmlinuz root=/dev/hda1 ...
initrd (hd1,1)/initrd

Suppose now that /boot is not on a separate partition, but resides on
the root partition, /dev/hdb1. Then your menu item looks like this:

root (hd1,0)
kernel /boot/vmlinuz root=/dev/hdb1 ....
initrd /boot/initrd

Here we need to preface the paths with "/boot" because it is now a
directory on (hd1,0), rather than a separate device. Again, the "root"
command may be left out, with proper device referencing:

kernel (hd1,0)/boot/vmlinuz root=/dev/hdb1 ....
initrd (hd1,0)/boot/initrd



--
Moral indignation is jealousy with a halo. -- HG Wells

--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx

< Previous Next >