LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Red Hat (https://www.linuxquestions.org/questions/red-hat-31/)
-   -   Redhat 9 RHN Kernel Update - Delete Old One (https://www.linuxquestions.org/questions/red-hat-31/redhat-9-rhn-kernel-update-delete-old-one-86898/)

junpit 08-29-2003 04:11 AM

Redhat 9 RHN Kernel Update - Delete Old One
 
Hi

I installed RH9 on my PC. Great!

I get to the point where I can optionally update using RHN. I enter my details and it shows me a new kernel. I select the kernel source rpm and the new compiled kernel.

Then I'm shown a set of updates available like bash etc. I select all on them. I kind of expected them to be automatically selected, but nevertheless I selected them.

All was OK. This morning when I turned on, grub showed me 2 installations. I want to get rid of the old one and I had to go through user setup and configuration like the night before.

Why has this happened twice? I want to delete the old one. What do I need to do? I haven't checked but hope that it hasn't created two completely independent OSs on the box.

Any help is greatly appreciated.

-Junpit

aqoliveira 08-29-2003 05:48 AM

Hi

No you don have to versions of OS installed but two kernel version installed on you machine.

e.g old = kernel 2.4.18
new = kernel 2.4.20

cd /boot
rm config-2.4.18
rm initrd-2.4.18.img
rm module-info-2.4.18
rm System.map-2.4.18
rm vmlinuz-2.4.18

cd /usr/src
rm -rf linux-2.4.18

cd /etc
vi grub.conf
hash or delete the old kernel label save the file and reboot system.

NB!! make sure u delete the right kernel version or else



:(

Bobmeister 08-29-2003 09:41 AM

You know....I think that it is safer to keep one older working version of the kernel laying around. Now, if you build up a lot of them, you can delete the oldest ones and keep the latest two. Also, it would be a good idea to keep a boot floppy for two working kernels. This way, if one ever malfunctioned or became corrupted, you can always boot into the older kernel and at least have access to the system (minus new modules that you might have built for the new kernel, of course).

I don't like my /boot and boot partitions to get too full either, but I will only delete the OLDEST of the kernels and leave the second to latest one there.

Just a thought.

misc 08-29-2003 09:50 AM

Don't. :tisk:

Don't edit the GRUB boot menu to delete old kernel entries.

To remove old entries in the boot menu, simply uninstall the old kernel packages. That will get rid of the boot menu entries automatically, too.

Example (user "root" at command-line):

# rpm --query --all 'kernel*'
kernel-2.4.20-20.9
kernel-2.4.20-19.9
kernel-utils-2.4-8.29
kernel-doc-2.4.20-20.9
kernel-source-2.4.20-20.9

# rpm --erase kernel-2.4.20-19.9

Bobmeister 08-29-2003 10:03 AM

Roger that....misc is correct. The RPM method is the way to go for this task. The GRUB menu will automatically delete the entry on splash screen.

I still recommend, however, that you leave at least TWO working kernels handy for use. I had FIVE on mine for a while and thought that was getting out of hand so I rpm's away three of them. It works well.

tktim 08-29-2003 02:23 PM

http://www.linuxquestions.org/questi...threadid=85965

I’ve upgrade RH8 to 2.4.20-19.8

If I were to install the boxed version RH9 now, would I be going backwards?

Bobmeister 08-29-2003 04:04 PM

Yes, because the ISO's for Red Hat come with 2.4.20-8.

However, you would be upgraded from up2date to the latest 2.4.20-20.9 which just came out last week. That way you will have the original kernel and the latest ready for use. Your 19.9 kernel would bite the dust, however, I think.

Can anyone correct me if I'm wrong on that?


All times are GMT -5. The time now is 08:24 AM.