LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-08-2003, 11:27 PM   #1
Grim Reaper
Member
 
Registered: Apr 2002
Distribution: Gentoo 2006.0 AMD64
Posts: 399

Rep: Reputation: 30
Very quick question about GRUB...


My first time using it...and I'm having a little trouble understanding its partitioning theory...

I have one hdd, with 3 partitions.

The first being the boot partition, 32meg big, flagged with Bootable..

the next partition is my host distro (Slackware) and the next partition is my under construction LFS distro...

The GRUB boot files are on the boot partition obviously, and i want the root partition to be /dev/hda6 (which is the LFS partition)...

Grub loads fine, but the line that i have specifying where the kernel is because it comes up "File not found"

The line is as such:

kernel (hd0,0)/boot/bzImage root=/dev/hda6


how _should_ this line read with the above info?
hopefully somebody understands what im after..

EDIT:
Ignore this post, I got it goin!
I got it to work with this line:

kernel (hd0,0)/bzImage root=/dev/hda6

Last edited by Grim Reaper; 01-08-2003 at 11:31 PM.
 
Old 01-09-2003, 02:13 AM   #2
membrax
Member
 
Registered: Nov 2002
Location: 50'48''N - 4'21''E
Distribution: SuSE7.1 - SuSE8.1 - SuSE8.2 - RH6.2 - RH7.1 - RH7.3 - RH8.0 - RH9.0 - Fedora Core 1
Posts: 281

Rep: Reputation: 30
GRUB defines its own disk notation so that disk partitions and slices can be indicated, regardless of the operating system that they happen to hold. The following example shows the general disk syntax:

(hdn,p)
where n is the disk number (starting at 0), and p is the partition number (again, starting at 0). For example, the second partition on the third hard disk would be designated as:

(hd2,1)

For operating systems that further subdivide the hard-disk partition, this syntax adds a third field consisting of the (sub)partition letter within the slice (physical partition). For example, the a partition in the first slice on the first hard disk under FreeBSD would be designated as:

(hd0,0,a)









Some GRUB Recipes

We're now ready to look at the GRUB configuration file (grub.conf). Here are some sample lines from its first, general section:


# general section
splashimage (hd0,0)/grub/splash.xpm.gz Pretty picture behind the menu.
default 0 Default boot entry (numbering starts at 0).
timeout 30 Menu timeout period in seconds.
password -md5 xxxxxxx Use grub-md5-crypt to encode password.

These lines specify the image displayed behind the boot menu, the menu timeout period and default entry to boot, and the boot password.

The remainder of the file specifies the items on the boot menu. Here are two examples that boot the Linux operating system on the first partition on the first hard disk (selecting different kernels):

title Linux
root (hd0,0)
kernel /vmlinuz ro root=/dev/hda2
initrd /initrd.img

title Test-Linux
root (hd0,0)
kernel /vmlinuz-test ro root=/dev/hda3
initrd /initrd.img-test

The title lines indicate the menu item text. The root lines specify the partition where the boot loader is located. All directory references are assumed to be relative to the root of this partition. Thus, the location of the vmlinuz files specified in the kernel lines is in the root directory of this partition.

The kernel lines specify the path to the Linux kernel in each case, along with any parameters to be passed to it. In this case, a separate /boot partition is being used, so the root parameter is passed to the kernel; the latter indicates the location of the system root directory (such as /). Thus, we can tell that the kernel images reside at /boot/vmlinuz* from the point of view of the booted Linux system. The initrd lines similarly specify the path to the initrd.img file (if used).
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
quick question about grub bootloader & installing another distro Ay-Karamba! Linux - Newbie 12 10-14-2005 09:00 AM
Quick GRUB question flashingcurser Debian 4 05-09-2005 10:02 AM
Quick question: Adding operating systems to Grub. Fenster Linux - Newbie 5 08-21-2004 05:42 PM
quick grub.conf question dot hog Linux - Newbie 1 10-17-2003 04:19 PM
A lil quick help with grub psyklops Linux - General 2 09-17-2003 06:11 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:46 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration