LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-02-2003, 10:02 PM   #1
madangsweh
Member
 
Registered: Jul 2003
Posts: 32

Rep: Reputation: 15
Removing previouse kerners


I have installed RH9.0 on my PC.
Since then, there were many upgrade of kerner, so now I see 5 kerners to select when boot screen is on.

I like to clean up some previous kerners on my system, but not sure what to remove. I see some files/directories in /boot , should I just remove those files/directories manually with /etc/grub.conf file?

Any comment will be welcome.

Also another question is I enabled NTFS support in my Linux, but after upgrade I always have to recompile the kerner, which is very annoying thing. Is there any way to preserve the previous kerner configuration without recompile?
 
Old 09-02-2003, 10:34 PM   #2
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Virginia, USA
Distribution: Debian 12
Posts: 8,337

Rep: Reputation: 548Reputation: 548Reputation: 548Reputation: 548Reputation: 548Reputation: 548
"I like to clean up some previous kerners on my system, but not sure what to remove."

There are three things to remove for each kernel that you want to remove.

1. The bootable kernel file in /boot

2. The loadable kernel files in /lib/modules which correspond to the kernel you took out of /boot

3. The entry for that kernel in /etc/grub.conf
 
Old 09-02-2003, 11:01 PM   #3
madangsweh
Member
 
Registered: Jul 2003
Posts: 32

Original Poster
Rep: Reputation: 15
Thanks for the reply.
For the bootable kerner files in /boot, I see many files such as module-info-..., vmlinux..., initrd-...., system.map..., config..... These are the files seem like related to previous kerner. Should I remove the all files there?
 
Old 09-03-2003, 02:08 PM   #4
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Virginia, USA
Distribution: Debian 12
Posts: 8,337

Rep: Reputation: 548Reputation: 548Reputation: 548Reputation: 548Reputation: 548Reputation: 548
"Should I remove the all files there?"

No, not all of the files. Some of the files in /boot are part of the kernel that you are using now. If you delete the kernel you are using now then you will not be able to boot.

I suggest that you backup /boot, /lib/modules, and /etc/grub.conf. Also you will need a rescue system like knoppix or tomsrtbt. Then if you make a mistake and delete the wrong kernel you can boot the rescue system and restore your kernel from your backup.

You will have to decide which files belong to which kernel. You can possibly do that by looking at the file creation dates. All of the files for any particular kernel were probably created on the same date.

You can find out your kernel version number by typing the command:
uname -r
Then list the directories in /lib/modules. One of the directories in /lib/modules will have the same name as your kernel version number. That directory is part of your current kernel. All other directories in /lib/modules belong to your other kernels. You can delete all of the directories in /lib/modules except the one belonging to your current kernel.

Make a boot floppy and check that it works. Then you can remove all of the extra entries in /etc/grub.conf. If you make a mistake then you can use the boot floppy to get back into Linux.
 
Old 09-03-2003, 04:28 PM   #5
madangsweh
Member
 
Registered: Jul 2003
Posts: 32

Original Poster
Rep: Reputation: 15
Thank a lot..
It worked out well..
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
Help removing Pr0metheus Slackware 11 03-19-2005 05:19 PM
Removing files wihtout removing containing Direcotry caps_phisto Linux - General 2 10-07-2004 08:16 AM
removing certain packages Smokey Red Hat 1 10-02-2004 07:55 PM
removing XP SP1 DAChristen29 General 2 10-16-2003 01:57 PM
Removing newline. Tarts Programming 2 10-16-2003 11:49 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:56 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