Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
quick grub question
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
shadowtux
n00b
n00b


Joined: 22 Aug 2005
Posts: 9

PostPosted: Mon Aug 22, 2005 5:33 am    Post subject: quick grub question Reply with quote

Ok I am running my hard drive on the second ide channel making it hdc and not hda, so my question is how do I change that in the grub? or is the grub "templete" going to just work for that? anyways thanks!
Back to top
View user's profile Send private message
fangorn
Veteran
Veteran


Joined: 31 Jul 2004
Posts: 1886

PostPosted: Mon Aug 22, 2005 6:04 am    Post subject: Reply with quote

at grub install you have to tell grub the partition where to look for its installation directory. So no, it will not work out of the box if you strictly hack in the commands from the handbook, but if you exchange the partitions from the example with the partitions you want it to be on your machine it will work without problems. IIRC the /dev/hdc drive is (hd2) in grub syntax, so the first primary partition would be (hd2,0) and the first logical partition (hd2,4). Set the root device correct, change the /boot/grub/grub.conf according to you're partition table and install grub to the place wherever you want it to be. If you don't wanna install it to the master boot record of the first harddisc, you will have to take care of it getting loaded by another boot manager (the Windows Bootmanager in a dual boot config for example, which is the most stable way to setup such a system)
Back to top
View user's profile Send private message
shadowtux
n00b
n00b


Joined: 22 Aug 2005
Posts: 9

PostPosted: Mon Aug 22, 2005 6:15 am    Post subject: Reply with quote

hey thanks I was just worried about the hd0,0 part seeing that I was on a different ide anyways thanks
Back to top
View user's profile Send private message
truc
Advocate
Advocate


Joined: 25 Jul 2005
Posts: 3199

PostPosted: Mon Aug 22, 2005 7:35 am    Post subject: Reply with quote

Hum, /dev/hdc is (hd2) only if /dev/hda and /dev/hdb are hard drives.

eg:
/dev/hda --> HD
/dev/hdb --> CDROM
/dev/hdc --> HD


Then /dev/hdc would be (hd1) and /dev/hda (hd0)
Back to top
View user's profile Send private message
syg00
l33t
l33t


Joined: 23 Aug 2004
Posts: 907
Location: Brisbane, AUS

PostPosted: Mon Aug 22, 2005 7:56 am    Post subject: Reply with quote

Or even (like this laptop)

/dev/hda --> CDROM
/dev/hdb --> empty
/dev/hdc --> HD


Then /dev/hdc is (hd0) - hard to generalise.
Back to top
View user's profile Send private message
fangorn
Veteran
Veteran


Joined: 31 Jul 2004
Posts: 1886

PostPosted: Mon Aug 22, 2005 8:35 am    Post subject: Reply with quote

clearly long time since I read the manual to grub :roll:
Back to top
View user's profile Send private message
shadowtux
n00b
n00b


Joined: 22 Aug 2005
Posts: 9

PostPosted: Mon Aug 22, 2005 4:07 pm    Post subject: How should I set my grub up? Reply with quote

Ok my motherboard is setup like this


IDE 1-
Unpopulated


IDE 2-
DVD Drive-salve
Hard drive-master

My partition is like this
Hard Drive
Hdc1- /boot
Hdc2- swap
Hdc3- /

Anyways I have made a grub config file before I understand everything about it I am just messing up somewhere lol. My current grub config looks like this

default 0
timeout 15
title=Gentoo Linux 2.6.11-gentoo-r3
root (0,2)
kernal /kernal-2.6.11-gentoo-r3 root=/dev/hdc2

The kernel listed in my /boot is in fact kernal-2.6.11-gentoo-r3

My device map shows
(hd0) /dev/hdc

This is different than what it was it had the floppy drive controller line in there until I took it out because I do not have a floppy drive.


So far I can get the grub file to the splash screen than I select the kernal I want to load and it flashes and goes right back to the splash screen. Anyways at least I am getting further than I was
.
Back to top
View user's profile Send private message
truc
Advocate
Advocate


Joined: 25 Jul 2005
Posts: 3199

PostPosted: Mon Aug 22, 2005 6:56 pm    Post subject: Reply with quote

Quote:
default 0
timeout 15
title=Gentoo Linux 2.6.11-gentoo-r3
root (0,2)
kernal /kernal-2.6.11-gentoo-r3 root=/dev/hdc2


Shouldn't it be
Quote:
default 0
timeout 15
title=Gentoo Linux 2.6.11-gentoo-r3
root (0,0)
kernal /kernal-2.6.11-gentoo-r3 root=/dev/hdc3


right?
Quote:
Hard Drive
Hdc1- /boot
Hdc2- swap
Hdc3- /
Back to top
View user's profile Send private message
shadowtux
n00b
n00b


Joined: 22 Aug 2005
Posts: 9

PostPosted: Tue Aug 23, 2005 4:17 am    Post subject: Reply with quote

sorry about that that was a typing mistake I actually did have it


kernal /kernal-2.6.11-gentoo-r3 root=/dev/hdc3

Anyways what is your reasoning for changing the root (0,0)?

I tried it and it did not work It still just boots and shows root (0,0) for a split second and I mean a split second and than goes back to the splash screen it is in like some kind of loop. Anyways hope to figure this out. This is turning out to be a good learning experience
Back to top
View user's profile Send private message
syg00
l33t
l33t


Joined: 23 Aug 2004
Posts: 907
Location: Brisbane, AUS

PostPosted: Tue Aug 23, 2005 4:32 am    Post subject: Reply with quote

root(hd0,0) is correct - this is where grub live (not your Linux root partition)

As for your other problem, try spelling kernel corrrectly.
Back to top
View user's profile Send private message
shadowtux
n00b
n00b


Joined: 22 Aug 2005
Posts: 9

PostPosted: Tue Aug 23, 2005 4:34 am    Post subject: Reply with quote

well I only spelled kernel like this becasue that is what it is named like in my boot partition so do I need to rename my kernel?
Back to top
View user's profile Send private message
syg00
l33t
l33t


Joined: 23 Aug 2004
Posts: 907
Location: Brisbane, AUS

PostPosted: Tue Aug 23, 2005 4:37 am    Post subject: Reply with quote

kernel /kernal-2.6.11-gentoo-r3 root=/dev/hdc3
Back to top
View user's profile Send private message
shadowtux
n00b
n00b


Joined: 22 Aug 2005
Posts: 9

PostPosted: Tue Aug 23, 2005 4:51 am    Post subject: Reply with quote

omg your a life saver I am so happy now thank you thank you thank you.
Back to top
View user's profile Send private message
shadowtux
n00b
n00b


Joined: 22 Aug 2005
Posts: 9

PostPosted: Tue Aug 23, 2005 5:06 am    Post subject: Reply with quote

ok new problem it is now after it starts to mount everythng during boot up these lines fail


* Starting devfsd
/sbin/rc: line 313: /sbin/devfsd: no such file or directory
*could not start /sbin/dev/fsd [!!]

*Checking root filesystem ...
failed to open the device '/dev/hdc2' :no such file or directory
*filesystem couldn't be fixed :( [!!]

give root passward for maintenance
(or type Control-D to continue)
Back to top
View user's profile Send private message
fangorn
Veteran
Veteran


Joined: 31 Jul 2004
Posts: 1886

PostPosted: Tue Aug 23, 2005 5:45 am    Post subject: Reply with quote

You have support for devfs in your kernel and tell the kernel to mount it automatically at boot. If you do that you will have to install devfsd on your gentoo system. But I would prefer UDEV. Just remove the option "Automatically mount /dev at boot" in your kernel config under PseudoFileSystems/devfs and install udev and if you want coldplug.
Back to top
View user's profile Send private message
truc
Advocate
Advocate


Joined: 25 Jul 2005
Posts: 3199

PostPosted: Tue Aug 23, 2005 6:35 am    Post subject: Reply with quote

Waou! I didn't even see this error (kernal )

btw
Quote:
*Checking root filesystem ...
failed to open the device '/dev/hdc2' :no such file or directory


Hum, /dev/hdc2 is your swap partition, you need to edit your fstab, cause your root partition ( / ) is /dev/hdc3
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum