Grub Manual

Les Mikesell lesmikesell at gmail.com
Fri Oct 19 15:15:49 UTC 2007


Karl Larsen wrote:

>> The things that are confusing are that grub only knows about one 
>> partition, which is the one where it is loading its config, ramdisk 
>> and the kernel from, so this is naturally the root while grub is 
>> booting, and it knows it only by bios conventions, since bios is the 
>> only way it can access anything before the kernel loads.
>    Actually grub uses two root messages. The root (hd0,0) is one and on 
> the end of the kernel line is a root=/dev/sda5 which is where the system 
> lives.

Yes, that's not grub's root, it's an instruction to the kernel that it 
loads.

>> Since grub isn't Linux specific, the docs and commands don't use Linux 
>> device name conventions even when they could (for the install steps).  
>> Also, /etc/grub.conf is a symlink for convenience just to match 
>> typical Linux conventions for where you expect config files to be.  
>> The real copy of this file has to be in /boot/grub/.  When you try to 
>> move your /boot partition around or have alternates, the symlink can 
>> end up pointing at a different place than the one actualy used during 
>> booting.
>>
>    Here is my experiance. I copied all of /boot from /dev/sda5 to 
> /dev/sda6 and then worked on /grub/grub.conf until I got over kernel 
> panic and such stuff. I deleted the /boot directory.

Grub can boot from any partition that bios can find, and you'd instruct 
grub about it with the root (hdx,x) notation for the drive/partition. 
It doesn't care about the linux device name, how the data got on that 
partition, or whether it is ever mounted anywhere once the system starts.

>    I got a kernel update but I soon saw it was not working. Then I 
> learned I need to mount /dev/sda6 to /boot. Since the update re-made 
> /boot that was easy :-)

The scripts that do the installation of a new kernel make some linux and 
distribution-related assumptions about where to make the changes.

>    Then I made /dev/sda7 for my karl which is my user name. I did that 
> without even reading grub because it is not covered. I just had to write 
> in fstab and it works just fine.
> 
>    These are the things you do not find in the grub manual or other 
> files, so it makes it hard.

Those things aren't really related to grub, which is why they aren't in 
the grub manual.  They are related to how a running fedora system finds 
the place from a linux perspective to make updates that grub will find 
on the next boot.  The reasons you have to get that part right don't 
have anything to do with grub itself, just conventions within fedora.

-- 
   Les Mikesell
    lesmikesell at gmail.com




More information about the users mailing list