Panic on boot - Bricked Kernel during upgrades


(B. Martinez) #1

I have a fpbx distro system, that was updating (system updates, not module updates) and somehow it failed the upgrade. Disk space isn’t an issue. During reboot the system issues a panic and hangs.

The panic error is: “Kernel panic - not syncing: VFS: Unable to mount root fs on unknown -block(0,0)”

If I manually intervene and have Grub boot off previous Kernel, it will boot into Emergency Mode. If I login, then exit, it will finish booting in the old kernel and everything will operate normally up until another reboot (in which case it will panic again). After getting it up, I yum update everything and that did not change/fix the issue.

This is a production system and it’s virtualized. I have current backups, but would prefer to repair the borked update. What is recommended way to get past this properly? It appears I may just need to somehow rebuild that failed kernel install or repair. I have seen some posts talking about rebuilding the ramfs image that the kernel uses during booting. I found a link which references this situation pretty clearly however not sure if others have ran into this before I go cowboy here:

How to Fix Kernel Panic - Not Syncing: VFS: Unable to Mount Root FS on Unknown-Block(0,0) https://www.geekswarrior.com/2019/07/solved-how-to-fix-kernel-panic-on-linux.html

System Info:

Sangoma Linux 7.8.2003

Kernel that won’t boot: 3.10.0-1127.19.1.e17.x86_64
Kernel that does work (previous version): 3.10.0-957.21.3.e17.x86_64


(Lorne Gaetz) #2

Often you can recover by booting from the working kernel and running

yum reinstall kernel

And then try booting from the new kernel again


#3

You say you are “virtualized” , by what method ?

I ask that because maybe you won’t be able to replace your kernel.


(B. Martinez) #4

It was virtualized from the get go in QEMU as are all the systems we manage. “yum reinstall kernel” solved the problem. We’re back in action without grub manual intervention. Cheers


#5

If you are not yet using gcow2 for your disks, then I encourage you to migrate them thusly and utilize snapshots on a timely fashion.