How do a fix a non working kernel installation ?

Seann Clark nombrandue at tsukinokage.net
Thu Jul 16 17:19:28 UTC 2009


linux guy wrote:
> No joy.  All I got was the same blinking cursor.  I'm running from the
> F9 Live CD.
>
> BTW: chroot above was actually /usr/sbin/chroot.   And the yum problem
> with the repos wasn't the repos at all.  The chroot session doesn't
> have access to the network.  ping www.google.com returns "unknown
> host" in the chroot session, whereas its found from a non chroot
> session.
>
> yum -C list kernel shows only the two F11 kernels.  The F12 kernel is gone.
>
> However, if I look at grub. conf in /media/-/boot, the entry for the
> F12 kernel is still there !  Furthermore so are the F12 kernel files.
>  So I am guessing that rpm didn't remove any of the actual files, even
> though it seems to have removed all of the database entries.  GREAT !
> I've got a mess on my hands.
>
> This makes sense, because if I do a cd /boot from the chroot session,
> it shows a blank directory.   However, if I cd to /media/-/boot, its
> definitely not empty.
>
> I think I need to link the /boot directory to /media/-/boot and then
> to an rpm -i against the F12 kernel rpm to reinstall the entries into
> the database and then do a rpm -e to actually remove the files.
>
> Does that make sense ?  Is there an easier way ?
>
> Thanks
>
>
> HOWEVER....
>
> On 7/16/09, linux guy <linuxguy123 at gmail.com> wrote:
>   
>> I think I got it fixed.  Here is what I did in case someone needs it someday
>> :)
>>
>> - booted F9 Live.  Just because I had it around.
>> - opened Dolphin, because it displays the hard drives for the machine
>> - opened a terminal in Dolphin
>> - browse to the root directory of the hard drive
>> - did a pwd in the terminal and found the root of my hard drive was
>> /media/-/
>> - su
>> - chroot /media/-/
>> - yum -C list kernel  <- did -C because the Fedora repos seem to be
>> messed up again, thus I only used the local cache data
>> - yum -C remove kernel-2.6.31-0.69.rc3.fc12
>> - this resulted in an error due to some unrelated pooched dependencies.
>> - rpm -e kernel-2.6.31-0.69.rc3.fc12
>> - this resulted in an error due to some unrelated pooched dependencies
>> - rpm --nodeps -e kernel-2.6.31-0.69.rc3.fc12
>> - rpm -e kernel-firmware-2.6.31-0.69.rc3.fc12
>>
>> I will now reboot and see if my system runs.  I'll report back in a
>> bit if it does.
>>
>> On 7/16/09, linux guy <linuxguy123 at gmail.com> wrote:
>>     
>>> Will chroot work when the target system has a broken kernel ?   It
>>> keeps running the old kernel ?
>>>
>>> I tried using rpm with --dbpath so that it used the F11 rpm data.  It
>>> wouldn't run because of incompatible rpm versions.
>>>
>>> On 7/16/09, davide <lists4davide at gmail.com> wrote:
>>>       
>>>> linux guy <linuxguy123 <at> gmail.com> writes:
>>>>
>>>>
>>>>         
>>>>>  I am now running from a Fedora 9 live CD I had laying around.  I can
>>>>>  see the hard drive and its partitions from the live session.  How
>>>>>  would I fix the F11 installation so it runs again ?  Is it possible to
>>>>>  do an rpm -e on the non running F11 partition from the F9 live session
>>>>>  ?
>>>>>           
>>>> You can take control of the installed linux from a live cd with the
>>>> chroot
>>>> command using the command line.
>>>> But you should know what you are doing.
>>>> Basically it is very simple and powerful, but for this reason you can
>>>> also
>>>> break
>>>> your system.
>>>>
>>>> --
>>>> fedora-list mailing list
>>>> fedora-list at redhat.com
>>>> To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
>>>> Guidelines:
>>>> http://fedoraproject.org/wiki/Communicate/MailingListGuidelines
>>>>
>>>>         
>
>   
To fix Grub fast and easy, after editing the kernel grouping, or 
anything else out of  /boot/grub/grub.conf, you can grab a livecd that 
works good on fixing a broken grub boot, called super grub disk (I have 
used it plenty of times when a borked boot of a fedora box happened to 
me) and it works great.  Biggest thing I can think of is edit grub.conf, 
and change the default to a known good kernel and remove the bad kernel 
out. That is to say you have a good one you can boot off of still on the 
system....

~Seann
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 5531 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://listman.redhat.com/archives/fedora-list/attachments/20090716/079258b9/attachment-0001.bin>


More information about the fedora-list mailing list