Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
another grub ide 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
carpman
Advocate
Advocate


Joined: 20 Jun 2002
Posts: 2202
Location: London - UK

PostPosted: Mon Sep 15, 2003 8:27 pm    Post subject: another grub ide question Reply with quote

Ok i am nearly there, i read a few threads but i still not 100% clear on grub set up.

I have hpt raid array with win2k, this is setup as:

primary partition - win2k 15gb disc0 part 1
extended partition with 2 logical -
Sharedata 10 gb part5
games 10gb part6

rest is setup for linux as follows these are more logical partitions

boot - disc0 part 7
swop - disc0 part 8
/ - disc0 part 9
home - disc0 part 10
storage - disc0 part 11

I have setup the grub device map as per this thread
http://forums.gentoo.org/viewtopic.php?t=73704&highlight=ide+raid+grub

my grub device.map file now looks like this

(fd0) /dev/floppy/0
(hd0) /dev/ataraid/disc0/disc


I have edited my grub.conf so it now reads

default 0
timeout 30
splashimage=(hd0,6)/boot/grub/splash.xpm.gz

title=Gentoo Sources 2.4
root (hd0,8)
kernel (hd0,6)/boot/bzImage root=/dev/ataraid/disc0/part9

title=Win2k
root (hd0,0)
chainloader (hd0,0)+1

Do the above look ok?


i beleive that all i have to do now is setup grub thus

grub> root (hd0,8)
grub> setup --stage2=/boot/grub/stage2 (hd0)
grub> quit

Now can i do the above in chroot or is i best done from grub boot disk?

also other post suggest doing --stage2=/boot/grub/stage2 (hd0)


any feed back welcome

cheers
Back to top
View user's profile Send private message
meowsqueak
Veteran
Veteran


Joined: 26 Aug 2003
Posts: 1549
Location: New Zealand

PostPosted: Mon Sep 15, 2003 11:13 pm    Post subject: Reply with quote

For the windows partition I use this:

Code:
title Win2k
rootnoverify (hd0,0)
chainloader +1


And *sometimes* I've had to stick a 'boot' on the end to actually make it work.
Back to top
View user's profile Send private message
cyrillic
Watchman
Watchman


Joined: 19 Feb 2003
Posts: 7301
Location: Groton, Massachusetts USA

PostPosted: Tue Sep 16, 2003 2:39 am    Post subject: Reply with quote

carpman wrote:
i beleive that all i have to do now is setup grub thus

grub> root (hd0,8)
grub> setup --stage2=/boot/grub/stage2 (hd0)
grub> quit

Now can i do the above in chroot or is i best done from grub boot disk?

If you install from a GRUB floppy, you won't need the device.map because it will see the actual BIOS drive mapping (instead of having to guess).

You can install from inside the chroot like this, or from your "real" system after booting with a floppy.
Code:
# cd /boot/grub
# rm *stage1_5        \\ This is a Highpoint BIOS workaround to avoid destroying the array
# grub --device-map=device.map
grub> root (hd0,6)
grub> setup (hd0)
grub> quit
Back to top
View user's profile Send private message
carpman
Advocate
Advocate


Joined: 20 Jun 2002
Posts: 2202
Location: London - UK

PostPosted: Tue Sep 16, 2003 8:16 am    Post subject: Reply with quote

Hello, thanks for reply cyrillic.

Not to sure about deleting stage1_5 just yet.

Did try booting from grub boot but kept getting errors when trying to setup grub, maybe because i have a drive on the normal ide primary channel.

i tried setting up grub from within chroot but get errors:
grub> root (hd0,6)
error 21: select disk does not exist

I use hd0,6 as boot partition because boot is on disc0 part7

If i look in /dev/ataraid i cannot find disc0 all that is listed is



d0 d0p12 d0p2 d0p6 d1 d1p12 d1p2 d1p6 d2 d2p12 d2p2 d2p6
d0p1 d0p13 d0p3 d0p7 d1p1 d1p13 d1p3 d1p7 d2p1 d2p13 d2p3 d2p7
d0p10 d0p14 d0p4 d0p8 d1p10 d1p14 d1p4 d1p8 d2p10 d2p14 d2p4 d2p8
d0p11 d0p15 d0p5 d0p9 d1p11 d1p15 d1p5 d1p9 d2p11 d2p15 d2p5 d2p9



sorry about this but i still confused :(
Back to top
View user's profile Send private message
carpman
Advocate
Advocate


Joined: 20 Jun 2002
Posts: 2202
Location: London - UK

PostPosted: Tue Sep 16, 2003 9:19 am    Post subject: Reply with quote

Ok sort not find disc0, had not mounted /dev before entering chroot.

Ok now with raid viewable from inside chroot i could not configure grub it would not complete root command, so i tried using grub boot disk, this worked ok with root (hd1,6).

I tired the next command
setup --stage2=/boot/grub/stage2 (hd1) also tried (hd0)

got error unrecognised command.


Tried setup (hd1) this worked but on reboot raid controller compalined of broken stripe on disk 2.

Is there a concise and refined howto on doing raid array grub setup?

I have read the install doc but this controdicted by some threads on forum, just need an up2date and straight forword guide that takes into account some other boot variables such as windows already on raid array and other disks on normal ide channel.


Going to boot from live cd and see if i can salvage things :(
Back to top
View user's profile Send private message
carpman
Advocate
Advocate


Joined: 20 Jun 2002
Posts: 2202
Location: London - UK

PostPosted: Tue Sep 16, 2003 9:25 am    Post subject: Reply with quote

Well it look like my whole raid array is shagged :(

Dam have to start all again, not sure if this is going tobe worth the trouble if i can't get the dam thing to boot :(


going off to sulk :(
Back to top
View user's profile Send private message
Barkotron
Apprentice
Apprentice


Joined: 05 Aug 2003
Posts: 253
Location: location, location.

PostPosted: Tue Sep 16, 2003 9:39 am    Post subject: Hi Reply with quote

I had this same problem:

As you have now found out, on a Highpoint raid array, you have to remove stage1_5 or you will destroy your raid array. There is a grub bug about this, but it doesn't look like anyone's going to do anything about it soon.

It is possible to get this back just by recreating the RAID array in the BIOS and then fdisking to the exact same points on the disc (you did make a record of your partition table, didn't you? :wink: )

From my troubles getting grub installed and gentoo running on the hpt372 controller (and relying very much on cyrillic's posts in other forums - without his postings I would never have got mine up and running, so muchos grazias :D ), I would say this is the way to do it:

1: use ac-sources. I was never able to get the RAID array up and running under gentoo-sources. I haven't tried 2.4.20-r7 yet though (now it's up I'm a bit reluctant to change it).
2:
Code:
emerge grub

3:
Code:
cd /boot/grub

4:
Code:
grub --device-map=device.map

5:
Code:
nano -w /boot/grub/device.map

6: Edit the device.map file to make sure that grub correctly identifies your ataraid as (hd<whatever>).
7:
Code:
rm /boot/grub/*stage1_5
- if you don't do this using a Highpoint 372 you will lose your RAID array and have to start again.
8:
Code:
grub --device-map=device.map

9:
Code:
root (hd<yourarray>,<yourbootpartition>)

10:
Code:
setup (hd<yourarray>)

11:
Code:
quit


Once you've done this, you should then be able to edit your grub.conf to enable you to boot into whatever you like.

Hope I haven't forgotten anything...
_________________
Give a man a fire and he'll be warm for a day: set fire to him and he'll be warm for the rest of his life.
Back to top
View user's profile Send private message
carpman
Advocate
Advocate


Joined: 20 Jun 2002
Posts: 2202
Location: London - UK

PostPosted: Tue Sep 16, 2003 9:56 am    Post subject: Reply with quote

Thanks for reply, at the moment i just really pissed off, it just takes so long to ge thing installed that when it goes wrong it takes days to get going again and i need to get a system up and running :(
Back to top
View user's profile Send private message
Barkotron
Apprentice
Apprentice


Joined: 05 Aug 2003
Posts: 253
Location: location, location.

PostPosted: Tue Sep 16, 2003 10:42 am    Post subject: it can be frustrating... Reply with quote

but as I said, if you keep a copy of your partition table, you can be back up and chrooted in to your already-emerged files in no time. Just recreate the RAID array using the same discs and same block size (important!), then boot off the liveCD,
Code:
fdisk /dev/ataraid/disc0/disc
then put the partitions back to the same cylinders you had them on. While I was trying to get that b*&£$%£ grub to work I must have done this a biiiiiiiillion times (exaggerate? moi? :wink: ) before I finally worked it out.

Alternatively, I managed to get at least some of my partitions back using mrecover2 - go here http://www.sudhian.com/showfaqs.cfm?fid=15&fcid=7#174 for a listing of various ways it's possible to get stuff back off you array.

Hope that might help...
_________________
Give a man a fire and he'll be warm for a day: set fire to him and he'll be warm for the rest of his life.
Back to top
View user's profile Send private message
cyrillic
Watchman
Watchman


Joined: 19 Feb 2003
Posts: 7301
Location: Groton, Massachusetts USA

PostPosted: Wed Sep 17, 2003 12:16 am    Post subject: Reply with quote

carpman,
I am sorry about your dearly departed array. :cry:

... but I can help you with your next attempt.

One thing you should know about GRUB :
The drive numbers (hd0), (hd1), (hd2), etc. directly follow the BIOS's boot order, so the boot drive = (hd0) *ALWAYS*
I originally assumed that you wanted to boot directly from the array, so this should have sent up a red flag when you found the array as (hd1)
carpman wrote:
Ok now with raid viewable from inside chroot i could not configure grub it would not complete root command, so i tried using grub boot disk, this worked ok with root (hd1,6).

Here, the BIOS is set to boot from one of the other drives before the array. You need to either change this in the BIOS, or install the bootloader on the drive that IS the boot drive. IMHO installing a bootloader to a drive that is not the boot drive is a mistake.

carpman wrote:
Is there a concise and refined howto on doing raid array grub setup?

No, since the BIOS treats the array as a single drive, GRUB cannot tell the difference between an array and a single drive, and the same installation procedure applies.
Back to top
View user's profile Send private message
carpman
Advocate
Advocate


Joined: 20 Jun 2002
Posts: 2202
Location: London - UK

PostPosted: Wed Sep 17, 2003 11:08 am    Post subject: Reply with quote

Hello, cyrillic and thanks for your reply.

Yes i did want to boot directly off the raid array and had set the bios to boot from scsi 1st as from what i had read in the docs for HPT controller card, this was the correct method. Seems not to have been though.

I did see there was an option in the kernel to boot from non motherboard controllers 1st but am not sure if this is a solution.

Any way this little adventure has made me re-think my decision to dual boot, maybe someone is telling me something, i am thinking about going for a straight linux install and use win4lin for must have windows software, games well i will just have to make them work in linux :)


Only problem now is getting my head around evms and linux software raid, boy do take the hard route :)


cheers
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