Sitemap

Deleting old kernel

Feb 5, 2022

If you are like me and like to have a separated /boot partition, it’s probable that times in time you end up running out f space to install new kernel versions.

To solve such type of problem you have to delete old versions you are not using any more.

To be easy to do that I prepared a one line command that do what you need.

dpkg -l | egrep "linux-(signed|modules|image|headers)" | grep -v $(uname -r | cut -d - -f 1) | awk {'print $2'} | xargs sudo apt purge -y

Enjoy!

--

--

Igor Iglesias
Igor Iglesias

Written by Igor Iglesias

Programador e empreendedor. Escrevo sobre Python, IA, automação e tecnologia prática pra quem quer evoluir rápido, sem enrolação.

No responses yet