LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 03-16-2022, 10:40 AM   #1
iqbala
Member
 
Registered: Dec 2003
Location: Milano (ITALY)
Distribution: Kubuntu 20.04
Posts: 285

Rep: Reputation: 32
removing old kernels does not cleanup the /boot partition


Hallo.
I am booted into 5.4.0-104-generic

I wanted to get rid of the old kernel versions, to free some space and keep my system clean.

Since the "autoremove" options seems to do nothing, I tried

sudo apt-get remove --purge linux-image-5.4.0-81-generic

In the /boot partition, actually, the files
initrd.img-5.4.0-81-generic
and
vmlinuz-5.4.0-81-generic
disappeared, but I still have the files
config-5.4.0-81-generic
vmlinuz-5.4.0-81-generic

Why this?
Can I safely rm them?
 
Old 03-16-2022, 11:47 AM   #2
hazel
LQ Guru
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 7,499
Blog Entries: 19

Rep: Reputation: 4410Reputation: 4410Reputation: 4410Reputation: 4410Reputation: 4410Reputation: 4410Reputation: 4410Reputation: 4410Reputation: 4410Reputation: 4410Reputation: 4410
If you can boot successfully with the new kernel and all the hardware works, you can delete anything that belongs to the old kernel. Though I'm puzzled that you name vmlinuz-5.4.0-81-generic both as a file that was cleared and as one that remains on disk. Maybe you meant System.map-5.4.0-81 the second time around.

The modules that went with the old kernel will form a separate package which you might also want to remove.
 
Old 03-17-2022, 08:37 AM   #3
iqbala
Member
 
Registered: Dec 2003
Location: Milano (ITALY)
Distribution: Kubuntu 20.04
Posts: 285

Original Poster
Rep: Reputation: 32
Yes, correct. I meant that. Thanks
 
  


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 upgrade kernels & its assundary other packages WITHOUT removing the old kernels ? babydr Slackware 14 03-16-2022 01:33 AM
Removing old kernels from /boot apachenew Linux - Kernel 4 09-19-2007 09:01 PM
Removing old kernels dbzw Linux - Newbie 5 02-29-2004 12:01 PM
Removing old kernels dbzw Linux - General 1 02-28-2004 11:33 PM
removing old kernels in RH 8.0 bobterri Linux - General 2 12-02-2002 09:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

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