LinuxQuestions.org
Visit Jeremy's Blog.
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 08-06-2003, 03:11 PM   #1
ByNature
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Rep: Reputation: 0
How to delete old kernel


Hi, Linux noob here... I have just installed RedHat 9 and during installation process downloaded and installed all suggested updates. I believe this is when kernel was updated from 2.4.20-8 to 2.4.20-19.9

But now during during startup in OS select menu, I get 3 choices: Dos, Linux 2.4.20-8 and Linux 2.4.20-19.9... It might be confusing to other users. How do I fix it so that only latest version shows up in the menu and delete old stuff so it doesn't take up space?

Also:

how do I view Linux logical drives? For example total space, free space, etc

Thanks
 
Old 08-06-2003, 03:25 PM   #2
aaa
LQ Guru
 
Registered: Jul 2003
Location: VA
Distribution: Slack 10.1
Posts: 2,194

Rep: Reputation: 47
Do you use LILO or Grub?
Just remove the stanza for the one you don't want in you lilo.conf or grub.conf. For LILO you have to run lilo to apply the changes.
 
Old 08-06-2003, 03:43 PM   #3
ksgill
Senior Member
 
Registered: Apr 2003
Location: Toronto, Canada
Distribution: Ubuntu Jaunty (9.04)
Posts: 1,044

Rep: Reputation: 45
rpm -e kernel-2.4.20-8
+
remove its entry from lilo/grub. Dont forget to remove
rpm -e kernel-source-2.4.20-8
(if its present.)
 
Old 08-06-2003, 06:27 PM   #4
ByNature
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Original Poster
Rep: Reputation: 0
rpm -e kernel-2.4.20-8 is this what I type in Run command? and how do I remove rpm -e kernel-source-2.4.20-8.. (complete noob, thanks for your help!)
 
Old 08-06-2003, 09:44 PM   #5
Mathieu
Senior Member
 
Registered: Feb 2001
Location: Montreal, Quebec, Canada
Distribution: RedHat, Fedora, CentOS, SUSE
Posts: 1,403

Rep: Reputation: 46
Yes, you can use the Run Command, but I suggest opening a terminal window.
In the Menu, look in System Tools and click on Terminal.

In the terminal, type:
Code:
rpm -e kernel-2.4.20-8
 
Old 08-06-2003, 09:52 PM   #6
ksgill
Senior Member
 
Registered: Apr 2003
Location: Toronto, Canada
Distribution: Ubuntu Jaunty (9.04)
Posts: 1,044

Rep: Reputation: 45
You dont remove rpm -e kernel-source-2.4.20-8..this is the command you type in console as root in order to remove the package(which, in this case is your old kernel)
 
Old 08-06-2003, 10:14 PM   #7
ByNature
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Original Poster
Rep: Reputation: 0
ok I ran those 2 lines:

[serge@localhost serge]$ rpm -e kernel-2.4.20-8
error: cannot get exclusive lock on /var/lib/rpm/Packages
error: cannot open Packages index using db3 - Operation not permitted (1)
error: cannot open Packages database in /var/lib/rpm
[serge@localhost serge]$ rpm -e kernel-source-2.4.20-8
error: package kernel-source-2.4.20-8 is not installed

does serge not have enough priviliges? I made the user part of adm group.

also where do I find grub.conf ? I tried searching for this file from root directory, but it says I need to run updatedb, which it seems I also don't have enough privileges

[serge@localhost serge]$ updatedb
fatal error: updatedb: You are not authorized to create a default slocate database!


aahh.. I feel like fish out of water, bear with me peeps.. also is there any good documentation on this stuff? like what the heck is rpm and etc?

Thank you.
 
Old 08-06-2003, 10:16 PM   #8
ksgill
Senior Member
 
Registered: Apr 2003
Location: Toronto, Canada
Distribution: Ubuntu Jaunty (9.04)
Posts: 1,044

Rep: Reputation: 45
Here, do this in console:

su -
this will prompt you for the root password. Input that and then do the above 2 commands that I gave you. in linux there are permissions to every file and directory..so you have to be root to do maintainence on your system (ex installing programs and removing them....etc etc.)
 
Old 08-06-2003, 10:17 PM   #9
DrOzz
Senior Member
 
Registered: May 2003
Location: Sydney, Nova Scotia, Canada
Distribution: slackware
Posts: 4,185

Rep: Reputation: 60
ok well you have to be root to install/uninstall rpm packages so "su -" to root and then uninstall it, also you have to be root to run updatedb....and the grub.conf file is in the /etc folder, oh and once again you have to be root to edit it

so before tackling any of these three things you want to do
type :
su -
and then the root password and then go about your business
 
Old 08-06-2003, 10:19 PM   #10
ksgill
Senior Member
 
Registered: Apr 2003
Location: Toronto, Canada
Distribution: Ubuntu Jaunty (9.04)
Posts: 1,044

Rep: Reputation: 45
Read this post for more on rpm's

http://www.linuxquestions.org/questi...threadid=79613
 
Old 08-06-2003, 10:28 PM   #11
ByNature
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Original Poster
Rep: Reputation: 0
Great help! How and where do I learn these commands? (besides Linux for dummies )
 
Old 08-06-2003, 10:32 PM   #12
ByNature
LQ Newbie
 
Registered: Aug 2003
Posts: 9

Original Poster
Rep: Reputation: 0
Ok now about editing grub.conf. I get permission denied even after I logged in as root..
 
Old 08-06-2003, 10:34 PM   #13
DrOzz
Senior Member
 
Registered: May 2003
Location: Sydney, Nova Scotia, Canada
Distribution: slackware
Posts: 4,185

Rep: Reputation: 60
here you can start with these couple of links..
http://www.laynetworks.com/linux.htm
http://www.reallylinux.com/docs/guru.shtml
http://www.unixguide.net/linux/linuxshortcuts.shtml
 
Old 08-06-2003, 10:34 PM   #14
ksgill
Senior Member
 
Registered: Apr 2003
Location: Toronto, Canada
Distribution: Ubuntu Jaunty (9.04)
Posts: 1,044

Rep: Reputation: 45
http://www.tldp.org/HOWTO/RPM-HOWTO/
http://gd.tuwien.ac.at/opsys/linux/L...-commands.html
http://www.er.uqam.ca/nobel/r10735/unixcomm.html
 
Old 08-06-2003, 10:35 PM   #15
DrOzz
Senior Member
 
Registered: May 2003
Location: Sydney, Nova Scotia, Canada
Distribution: slackware
Posts: 4,185

Rep: Reputation: 60
show the steps you've taken to edit it from logging in as root right to the point of trying to save it.
 
  


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
How to I fully delete every trace of kernel modules ??? Tsuroerusu Linux - Software 1 02-13-2005 12:26 PM
Delete old kernel yotamk Linux - Newbie 2 12-28-2004 10:39 AM
How to delete kernel?? harlemno1 Linux - Software 6 11-23-2004 07:38 AM
Redhat 9 RHN Kernel Update - Delete Old One junpit Red Hat 6 08-29-2003 04:04 PM
Delete kernel log Linux - Newbie 3 12-20-2002 03:04 AM

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

All times are GMT -5. The time now is 06:59 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
Open Source Consulting | Domain Registration