LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 09-10-2006, 05:28 PM   #1
dansawyer
Member
 
Registered: Mar 2005
Posts: 124

Rep: Reputation: 15
grub and grub.conf -


This is a general question regarding grub.conf. Below is a line from grub.conf. There are two 'root' entries. The first is a "root (hd0,0)". It appears this is the grub directive that tells grub where the kernel and initrd files are located. Is this correct?

The second, "root=/dev/sda2" tells grub where the / partition is located? Is this true?

Finally, is it possible to 'redirect' grub to a second disk? This used to be possible with lilo. One could build a single link to a second disk and lilo would redirect to that disk. The system has a second disk with several bootable images. I would simply tell grub - redirect to disk hd1.

title Fedora Core (2.6.17-1.2174_FC5smp)
root (hd0,0)
kernel /vmlinuz-2.6.17-1.2174_FC5smp ro root=/dev/sda2 rhgb quiet
initrd /initrd-2.6.17-1.2174_FC5smp.img

Thanks - Dan
 
Old 09-10-2006, 07:33 PM   #2
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,126

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
Quote:
Originally Posted by dansawyer
The first is a "root (hd0,0)". It appears this is the grub directive that tells grub where the kernel and initrd files are located. Is this correct?
Yep, close enough.
Quote:
The second, "root=/dev/sda2" tells grub where the / partition is located? Is this true?
Grub couldn't care less - unless you happen to have /boot mounted on the same partition. This "root" is actually a kernel parameter that grub is merely passing on.
Quote:
Finally, is it possible to 'redirect' grub to a second disk?
Certainly. (hd0,?) refers to partitions on the first disk, (hd1,?) refers to the second disk, etc.

Plenty of threads here, or check the manual for grub.
 
Old 09-11-2006, 08:26 AM   #3
dansawyer
Member
 
Registered: Mar 2005
Posts: 124

Original Poster
Rep: Reputation: 15
Thank you. What would a redirect rule look like? I would like to create an entry for grub to redirect to the second drive and list the boot options from that drive.

Thanks - Dan
 
Old 09-11-2006, 10:20 AM   #4
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 4,170

Rep: Reputation: 244Reputation: 244Reputation: 244
Quote:
Originally Posted by dansawyer
Thank you. What would a redirect rule look like? I would like to create an entry for grub to redirect to the second drive and list the boot options from that drive.

Thanks - Dan
Ok so you want to have two grub screens when you boot eg. you boot first grub splash comes up you select entry for second drive then it takes you to the the grub located in second drive MBR. If so then use an entry similar to like it uses for loading windows.

Code:
title           Microsoft Windows XP Professional
root            (hd0,0)
savedefault
makeactive
chainloader     +1
Changing to.
Code:
title           Second Linux Install Drive
rootnoverify     (hd1)
chainloader     +1
At least I think something like this should work never tried it myself you should be able to test if it will by hitting the c key at the first grub splash then entering.

Code:
rootnoverify     (hd1)
chainloader     +1
boot
And you should get your second grub splash.
 
  


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
Boots to grub; can't FIND grub.conf, start1 pushtostart Fedora 10 10-09-2006 05:01 PM
how to edit grub.conf from grub shell during booting pashaikh Linux - Security 1 06-27-2006 05:01 AM
grub can find grub.conf, how do i make it permanent? lankydenny Linux - Newbie 8 06-13-2006 06:47 PM
can some fc4 user mail his grub.conf and tell me how can i make this grub read this amolgupta Linux - Software 1 03-15-2006 04:04 AM
commands work with interactive grub, but not in grub.conf richardg Linux - Newbie 2 11-23-2003 04:36 AM

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

All times are GMT -5. The time now is 12:48 AM.

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