Categories
Linux Mastering Development Ubuntu

Kernel Panic on the default kernel

I have kernel panic on my default kernel (v.4.15.108) and it boots to initramfs only. If I change to the previous kernel (v.4.15.101), I am able to successfully boot my machine and everything is working correctly. I got that by trying to revert to a previous btrfs snapshot. I am running Ubuntu 18.04 with btrfs filesystem.

I have executed the following:

sudo apt-get purge linux-image-4.15.0-108-generic
sudo apt-get purge linux-headers-4.15.0-108-generic
sudo apt autoremove -y 
sudo update-initramfs -u -k 4.15.0-101-generic
sudo update-grub

but when I reboot my system, it still tries to boot to the default kernel and I am stuck at initramfs. I guess fixing this should be very easy and straight-forward but I really don’t know how to force the default grub to ignore kernel v.4.15.108. It is strange that even if I execute sudo apt upgrade it doesn’t find the new kernel. I thought that re-installing the kernel my fix my issue, but after I have installed the new kernel v.4.15.108, image, image-generic and headers, when I restart I don’t even get to initramfs, I have just a blinking underscore on a black screen.

Leave a Reply

Your email address will not be published. Required fields are marked *