You are not logged in.

#1 2020-12-05 17:26

Rademes
Member
From: Latvia
Registered: 2015-12-13
Posts: 636

[Solved]How to remove old Kernels?

Good afternoon!
After some updates, I have three kernels installed on my Q4OS Centaurus (attachment).
How can I remove (purge completely) old unused kernels?
I am ashamed to admit it, but I still don't know how to do it.

Also, how can I hold kernel to prevent it to be auto-updated?

Last edited by Rademes (2020-12-05 19:52)


Attachments:
png Kernels.png, Size: 71.33 KiB, Downloads: 297

Before asking for help please read this topic: https://www.q4os.org/forum/viewtopic.php?id=3502   If you have problems with WiFi network, try to install the Network Manager using Q4OS Software Centre.

Offline

#2 2020-12-05 18:01

Dave67
Member
Registered: 2020-02-14
Posts: 14

Re: [Solved]How to remove old Kernels?

The safest way is to use

sudo apt autoremove

Though today I saw on Q4OS a odd issue if I use uname -r  to check the kernel version I get 4.19.0.11. If I go on synaptic and search for  linux-image. I see that 4.19.0.12 is installed and 4.19.0.11 is not. now thats odd.


I hope I can solve your problem smile

Offline

#3 2020-12-05 18:09

Rademes
Member
From: Latvia
Registered: 2015-12-13
Posts: 636

Re: [Solved]How to remove old Kernels?

sudo apt autoremove does not removes kernels completely.
Also I want to know how to manually remove them. For example, I have kernels A, B, C. Kernel C is newest and active. How can I completely remove (purge) kernels A and B?
And how can I hold kernel C to prevent future updates of it?


Before asking for help please read this topic: https://www.q4os.org/forum/viewtopic.php?id=3502   If you have problems with WiFi network, try to install the Network Manager using Q4OS Software Centre.

Offline

#4 2020-12-05 18:28

Dave67
Member
Registered: 2020-02-14
Posts: 14

Re: [Solved]How to remove old Kernels?

Backup your system first. Search for linux-image example linux-image 4.19.0.11  in synaptic right click and select complete removal.

To freeze a package read this

https://www.snel.com/support/how-to-blo … in-debian/

Last edited by Dave67 (2020-12-05 18:40)


I hope I can solve your problem smile

Offline

#5 2020-12-05 18:59

Dave67
Member
Registered: 2020-02-14
Posts: 14

Re: [Solved]How to remove old Kernels?

I recommend foxclone for backups and cloning. I used it to clone my HDD to a SDD on my laptop.

https://www.foxclone.com/


I hope I can solve your problem smile

Offline

#6 2020-12-05 19:03

q4osteam
Q4OS Team
Registered: 2015-12-06
Posts: 4,248
Website

Re: [Solved]How to remove old Kernels?

You need to run:
$ sudo apt --purge remove linux-image-4.19.0-9-amd64

Offline

#7 2020-12-05 19:49

Rademes
Member
From: Latvia
Registered: 2015-12-13
Posts: 636

Re: [Solved]How to remove old Kernels?

Thank you Dave67 and q4osteam!
I have removed old kernels and their headers!
I use Timeshift and Clonezilla Live for system backups.

Last edited by Rademes (2020-12-05 19:55)


Attachments:
png OneKernel.png, Size: 65.21 KiB, Downloads: 310

Before asking for help please read this topic: https://www.q4os.org/forum/viewtopic.php?id=3502   If you have problems with WiFi network, try to install the Network Manager using Q4OS Software Centre.

Offline

Board footer

Powered by FluxBB