Wednesday, September 23, 2020

removing old kernel headers

An update to my previous post about clearing up disk space by clearing old kernel images - on this machine running Linux Mint 18.3, it appears purge-old-kernels was not removing the kernel headers. Following the post at https://www.pontikis.net/blog/remove-old-kernels-debian-ubuntu for the manual process, 

dpkg --list | grep linux-image

- old kernel images were being purged by purge-old-kernels

dpkg --list | grep linux-headers

- were not being purged.

So, did with

sudo apt-get --purge remove linux-headers-4.15.0-7* linux-headers-4.15.0-6* linux-headers-4.15.0-5* linux-headers-4.15.0-4* linux-headers-4.15.0-3* linux-headers-4.15.0-2*

and so on, since current kernel and previous one were linux-headers-4.15.0-118 and 117. This cleared up 3 GB or so.

No comments:

Post a Comment