LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices

Reply
 
Search this Thread
Old 02-09-2004, 01:39 PM   #1
allenpanther
LQ Newbie
 
Registered: Jan 2004
Posts: 6

Rep: Reputation: 0
GRUB to recover?


I mistakenly copied an extremely large file to the wrong location, in root, on hd1 and had problems booting...I didn't know how to fix it, and installed another copy of rh9 on hd2, which installed GRUB, booted from it, and saw and fixed my mistake. Now, however, I can't figure out how to get back to square one.

Now I want GRUB to boot from hd1,5, but can't make it work. The old install used LILO. Do I HAVE to use vmlinuz...I've never compiled a kernel? The reason that I want to boot from my first installation is that I spent many, many hours installing programs such as Mplayer, WINE, etc, and really don't want to have to go through all of that again ( newbie). The older, preferred install is on a 10G partition, and the new only has 3G, so I'm at a loss what to do.

Alternatively, can I just hard-link the old onto the new...? Really confused by so many options, and too inexperienced to know the best root to take.

Thanks. Allen
 
Old 02-09-2004, 04:48 PM   #2
Andrew Benton
Senior Member
 
Registered: Aug 2003
Location: Birkenhead/Britain
Distribution: Linux From Scratch
Posts: 2,073

Rep: Reputation: 64
If I were you I'd add your old install to the new /boot/grub/menu.lst
Grub has a different format/syntax/whatever to lilo, but you should be able to figure it out. It starts counting from zero so what was 1, grub calls 0.
/dev/hda5 grub calls hd(0,4) and /dev/hdb4 grub calls hd(1,3)
Did you get that? The rest of the options are basically the same as lilo
For example, this is an entry from /etc/lilo.conf to boot Mandrake
Code:
image=/boot/vmlinuz
	label="Mandrake"
	root=/dev/hda6
	initrd=/boot/initrd.img
	append="devfs=mount hdc=ide-scsi acpi=off quiet"
	vga=788
	read-only
And this is to boot the same thing in /boot/grub/menu.lst
Code:
title Mandrake
kernel (hd0,5)/boot/vmlinuz root=/dev/hda6 quiet devfs=mount
hdc=ide-scsi acpi=off vga=788
initrd (hd0,5)/boot/initrd.img
I find grub works better than lilo. Keep both your installs. You may need a lifeboat to climb into again.
 
Old 02-09-2004, 08:19 PM   #3
allenpanther
LQ Newbie
 
Registered: Jan 2004
Posts: 6

Original Poster
Rep: Reputation: 0
Thanks Andy!
I compared my own hda4 LILO.conf, and my hdb6 LILO.conf , with my hdc GRUB.conf ( or menu.lst, as is more correct) per your instructions ( I think at one point I had seven lucky windows open)( the essentail clue was the ( hd#,x) indicated at the beginning of the path) and saw the error of my ways...I fixed the code in GRUB and re- grub-install -ed. BOOM...I'm back in the pink! You gave me all of the clues that I needed. Apparently my second drive hadn't been mapped, so I had to edit the map file and re-do grub-install.. Can I send you a Cantaffordya fruit-basket or something...?or maybe come across the Atlantic and p l a y . . . .? Yer an anchell. -Allen

By the way? I agree with you completely about GRUB...it ( apparently) can boot anything anywhere anytime.. you can even boot Winblows ( or is it windoze..?) from your second hard-drive...I'm blown away! I have wanted to boot the ( better) saved copy of 98SE from hdb for a very long time, although WINE is getting stronger and stronger... ( and sooner rather than laterI'm going to reformat Mr. Gates last remaining 'partition' and then....

The rest was history.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
recover grub j0hn_galt Linux - Newbie 3 06-11-2005 02:26 AM
how to recover GRUb of FC2 ??? executive Linux - General 1 04-18-2005 05:58 AM
Recover/edit of /etc/inittab from GRUB sujith_marar Linux - General 1 09-11-2004 02:19 PM
Gentoo, grub recover? berkay Linux - General 4 08-25-2004 11:18 AM
how to reinstall/recover grub? Present Linux - General 6 02-11-2004 12:12 AM


All times are GMT -5. The time now is 12:45 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration