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 - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 07-09-2004, 10:33 PM   #1
Mitchua
LQ Newbie
 
Registered: Feb 2004
Posts: 11

Rep: Reputation: 0
How to fix broken (Gentoo) initrd from (Knoppix) boot disk


System: Gentoo on AMD Athlon XP 1800+, Radeon 9600Pro. 512MB

Pleeeeeeeeease help me :-)

I was running kernel 2.6.3 and decided to upgrade to 2.6.7. I did "make xconfig && make bzImage && make modules && make modules_install" then copied bzImage to /boot/bzImage-2.6.7. I copied the 2.6.3 entry in LILO and replaced 2.6.3 with 2.6.7. Obviously, it didn't work because I was missing an initrd. So I loaded back into 2.6.3 and used Gentoo's "genkernel initrd" to create a new initrd. IT OVERWROTE MY initrd-2.6.3! So I gave it --basedir=/usr/src/linux-2.6.7 and it outputted /boot/initrd-2.6.7. I changed my lilo and rebooted. "Kernel panic"...said something about there being a problem with RAMDISK (that's initrd, right?).

I tried going back to 2.6.3 but the new initrd is messed up too and I get a Kernel panic there too. I know now that I should have just done "make" to generate the proper initrd but now I'm stuck with no operational kernel. How can get back into my system? How can I recompile a proper initrd-2.6.7 from outside the system? From Knoppix?

I'd REALLY appreciate any help. I'm forced to use Windows in the mean time and it's eating away at me :-) THANK YOU for your help.

--Mitchua
 
Old 07-09-2004, 11:02 PM   #2
SciYro
Senior Member
 
Registered: Oct 2003
Location: hopefully not here
Distribution: Gentoo
Posts: 2,038

Rep: Reputation: 51
chroot into Gentoo from knoopix, delete the files in /boot, clean the kernel sources, and this time compile it correctly?, then remake the initrd , configure and run lilo, and see if ti works?

(and when did it say there was a ram-disk problem, before or after kernel loaded, and before or after init loaded? ... and what do you need the initrd for anyways? (if its just for smelting fancy you can try booting without the initrd))
 
Old 07-10-2004, 11:13 AM   #3
Mitchua
LQ Newbie
 
Registered: Feb 2004
Posts: 11

Original Poster
Rep: Reputation: 0
Quote:
Originally posted by SciYro
chroot into Gentoo from knoopix, delete the files in /boot, clean the kernel sources, and this time compile it correctly?, then remake the initrd , configure and run lilo, and see if ti works?

(and when did it say there was a ram-disk problem, before or after kernel loaded, and before or after init loaded? ... and what do you need the initrd for anyways? (if its just for smelting fancy you can try booting without the initrd))
AH, gotcha. I'll try it right now. Thank you!

It went through the drive detection then entered into a series of errors about ramdisk, hard drive, invalid init=, etc. before finally saying "Kernel panic".
 
Old 07-10-2004, 12:53 PM   #4
Mitchua
LQ Newbie
 
Registered: Feb 2004
Posts: 11

Original Poster
Rep: Reputation: 0
I'm having problems running lilo from Knoppix. I copied my lilo.conf to /etc/lilo.conf (on the Knoppix ramdisk) and ran "lilo -M /dev/hda6" but I just get Fatal: creat /boot/boot.0300: No such file or directory. How do I write the new lilo?

Thanks again.
 
Old 07-10-2004, 02:16 PM   #5
Mitchua
LQ Newbie
 
Registered: Feb 2004
Posts: 11

Original Poster
Rep: Reputation: 0
Found the answer myself.

From the Knoppix cmd prompt:
su
mount -o bind /dev /mnt/hda6/dev
chroot /dev/hda6
lilo

I'm back in Linux. Thanks for everyone's help.
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Cannot boot/install Fedora/knoppix/gentoo on Dell Dimension 9100 jpdm Linux - Hardware 2 10-26-2005 08:31 PM
how to make initrd.img for your kernel without boot disk? donaldtalbert Linux - Software 1 06-19-2005 10:30 PM
Boot disk broken - Can't boot tesa Slackware 6 04-24-2005 08:18 AM
USB Disk boot with Knoppix? Erik Plaggenmar Linux - Hardware 3 12-01-2004 05:30 AM
How to Fix Your Master Boot Record with Knoppix simsjr Linux - General 5 04-25-2004 09:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:45 PM.

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