Welcome to Dream.In.Code
Getting Help is Easy!

Join 98,767 Programmers for FREE!. Ask your question and get quick answers from Dream.In.Code experts. There are 1,030 online right now! We're the #1 programming help community on the internet! Registration is fast and FREE... Join Now!

Chat LIVE With a Expert

Register to Make This Box Go Away!


Grub.conf help

 
Reply to this topicStart new topic

Grub.conf help, Need help editing grub

Delta_Echo
post 23 Apr, 2008 - 01:33 AM
Post #1


D.I.C Regular

***
Joined: 24 Oct, 2007
Posts: 304


My Contributions


I installed gentoo linux on my second hdd. I skipped the grub install step in the Amd64 Gentoo Handbook
because i want to just use the bootloader on my Fedora install.

But when i try to boot gentoo i get a grub error.
This is my hdd info:
CODE

Disk /dev/sda: 320.0 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x1f1f1f1f

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          25      200781   83  Linux
/dev/sda2              26       38913   312367860   8e  Linux LVM

Disk /dev/sdb: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x4b36bdea

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1         123      987966   83  Linux
/dev/sdb2             124         246      987997+  82  Linux swap / Solaris
/dev/sdb3             247       19457   154312357+  83  Linux

Disk /dev/dm-0: 317.7 GB, 317726916608 bytes
255 heads, 63 sectors/track, 38628 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

Disk /dev/dm-0 doesn't contain a valid partition table

Disk /dev/dm-1: 2080 MB, 2080374784 bytes
255 heads, 63 sectors/track, 252 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x30307800

Disk /dev/dm-1 doesn't contain a valid partition table


This is my grub.conf:
CODE

# EDITED BY DELTA
# Note that you do not have to rerun grub after making changes to this file
# NOTICE:  You have a /boot partition.  This means that
#          all kernel and initrd paths are relative to /boot/, eg.
#          root (hd1,0)
#          kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00
#          initrd /initrd-version.img
#boot=/dev/sdb
default=0
timeout=5
splashimage=(hd1,0)/grub/splash.xpm.gz
hiddenmenu
title Fedora (2.6.24.4-64.fc8)
    root (hd1,0)
    kernel /vmlinuz-2.6.24.4-64.fc8 ro root=/dev/VolGroup00/LogVol00
    initrd /initrd-2.6.24.4-64.fc8.img
title Fedora (2.6.23.1-42.fc8)
    root (hd1,0)
    kernel /vmlinuz-2.6.23.1-42.fc8 ro root=/dev/VolGroup00/LogVol00
    initrd /initrd-2.6.23.1-42.fc8.img
title Gentoo (kernel-2.6.19-gentoo-r5)
        root (sd1,0)
        kernel /boot/kernel-2.6.19-gentoo-r5 root=/dev/sdb3


My gentoo install is located on /dev/sdb

Is my grub.conf written correctly?
Or is it something else?
On alot of parts of the grub install i was confused by the options so i chose the default option whenever i
didn't know what to do.

Thanks guys.

User is offlineProfile CardPM

Go to the top of the page


no2pencil
post 23 Apr, 2008 - 01:40 AM
Post #2


Wet D.I.C.

Group Icon
Joined: 10 May, 2007
Posts: 4,208



Thanked 15 times

Dream Kudos: 2275

Expert In: Goofing Off

My Contributions


QUOTE(Delta_Echo @ 23 Apr, 2008 - 04:33 AM) *

But when i try to boot gentoo i get a grub error.

& what might that error be... so we know what to look for?

Judging from the size of your partitions, I would assume that your root drive would be on the same partition as the kernel.

CODE

title Gentoo (kernel-2.6.19-gentoo-r5)
        root (sd3,0)
        kernel /boot/kernel-2.6.19-gentoo-r5 root=/dev/sdb3


How did you come up with the size of 123 anyhow? If you are going to make it that small, why have it anyway? I would just use sda1 as your root & sda2 for your swap.
User is offlineProfile CardPM

Go to the top of the page

Delta_Echo
post 23 Apr, 2008 - 01:49 AM
Post #3


D.I.C Regular

***
Joined: 24 Oct, 2007
Posts: 304


My Contributions


123? Its the boot partition. I set it to 1g with fdisk. Guess i screwed up......
The gentoo handbook wanted me to set it to 32m i thought that was too small.
Btw, what does the swap partition do?

This post has been edited by Delta_Echo: 23 Apr, 2008 - 01:53 AM
User is offlineProfile CardPM

Go to the top of the page

no2pencil
post 23 Apr, 2008 - 01:51 AM
Post #4


Wet D.I.C.

Group Icon
Joined: 10 May, 2007
Posts: 4,208



Thanked 15 times

Dream Kudos: 2275

Expert In: Goofing Off

My Contributions


1Gig would be 1024.

http://www.linuxhq.com/guides/SAG/x885.html
User is offlineProfile CardPM

Go to the top of the page

Delta_Echo
post 23 Apr, 2008 - 01:59 AM
Post #5


D.I.C Regular

***
Joined: 24 Oct, 2007
Posts: 304


My Contributions


Hmm...so i made a partition of 123kb......wow
Anyway, the grub error is "23:Error while parsing number"
User is offlineProfile CardPM

Go to the top of the page

no2pencil
post 23 Apr, 2008 - 02:06 AM
Post #6


Wet D.I.C.

Group Icon
Joined: 10 May, 2007
Posts: 4,208



Thanked 15 times

Dream Kudos: 2275

Expert In: Goofing Off

My Contributions


QUOTE

grub does not speak 'sd0, sd1', etc.

Instead it sees hard drives as hd0, hd1, etc.


I found from doing a Google search on that error.
http://www.linuxquestions.org/questions/li...-number-335563/
User is offlineProfile CardPM

Go to the top of the page

Delta_Echo
post 23 Apr, 2008 - 02:15 AM
Post #7


D.I.C Regular

***
Joined: 24 Oct, 2007
Posts: 304


My Contributions


so sdb1 would be (hd2.0)?

This post has been edited by Delta_Echo: 23 Apr, 2008 - 02:16 AM
User is offlineProfile CardPM

Go to the top of the page

no2pencil
post 23 Apr, 2008 - 02:18 AM
Post #8


Wet D.I.C.

Group Icon
Joined: 10 May, 2007
Posts: 4,208



Thanked 15 times

Dream Kudos: 2275

Expert In: Goofing Off

My Contributions


sb1 would be hd0, since the bootable flag is set, according to your fdisk.
User is offlineProfile CardPM

Go to the top of the page

Delta_Echo
post 23 Apr, 2008 - 02:21 AM
Post #9


D.I.C Regular

***
Joined: 24 Oct, 2007
Posts: 304


My Contributions


Hmm, i got it to boot...kinda
I get this:

No filesystem could mount root,tried:
kernel panic-no syncing:VFS:unable to mount root fs on unknown-block(0,0)



umm...wtf?
any ideas?

This is my new grub.conf:
CODE

# EDITED BY DELTA
# Note that you do not have to rerun grub after making changes to this file
# NOTICE:  You have a /boot partition.  This means that
#          all kernel and initrd paths are relative to /boot/, eg.
#          root (hd1,0)
#          kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00
#          initrd /initrd-version.img
#boot=/dev/sdb
default=0
timeout=5
splashimage=(hd1,0)/grub/splash.xpm.gz
hiddenmenu
title Fedora (2.6.24.4-64.fc8)
    root (hd1,0)
    kernel /vmlinuz-2.6.24.4-64.fc8 ro root=/dev/VolGroup00/LogVol00
    initrd /initrd-2.6.24.4-64.fc8.img
title Fedora (2.6.23.1-42.fc8)
    root (hd1,0)
    kernel /vmlinuz-2.6.23.1-42.fc8 ro root=/dev/VolGroup00/LogVol00
    initrd /initrd-2.6.23.1-42.fc8.img
title Gentoo (kernel-2.6.19-gentoo-r5)
        root (hd0,0)
        kernel /boot/kernel-2.6.19-gentoo-r5 root=/dev/sdb3


This post has been edited by Delta_Echo: 23 Apr, 2008 - 02:31 AM
User is offlineProfile CardPM

Go to the top of the page

Fast ReplyReply to this topicStart new topic
Time is now: 7/20/08 03:42PM

Live Help!

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

Bye Bye Ads

Free DIC T-Shirt

T-Shirt Example

Related Sites

Monthly Drawing

Thumb Drive

Partners

Top Contributors

Top 10 Kudos This Month
-->