Newbie from Baghdad need help

Greetings to all beautiful people out there
This is a newbie sysadmins from Baghdad trying to find his way out in enormous Linux realm
If I may ask, I want to dig deep to the cause of this kernel panic problem which occurred after series of hard powering off the machine couples times
The snapshot of my screen is below:


Steps that I tried:
I have tried to go and use rescue mode in which ends up to the same kernel panic screen
Please, I would like your assistance regarding this matter
YOURS

1 Like

Hi,

Looks like a corrupt kernel to me, booting an old kernel and reinstalling should fix. Please try:

On reboot press ALT-CTRL-DELETE, should bring up the grub menu if not more details can be found here:

https://fedoraproject.org/wiki/Changes/HiddenGrubMenu#How_To_Test

Select the most recent working kernel (should be the 2nd on down list).

Hopefully you should have a working system, but will be on and old kernel and at this point you back to the same problem on restart. Please open a terminal and issue rpm -qa | grep kernel | sort

output:

abrt-addon-kerneloops-2.14.5-1.fc33.x86_64
kernel-5.11.10-200.fc33.x86_64
kernel-5.11.11-200.fc33.x86_64
kernel-5.11.9-200.fc33.x86_64
kernel-core-5.11.10-200.fc33.x86_64
kernel-core-5.11.11-200.fc33.x86_64
kernel-core-5.11.9-200.fc33.x86_64
kernel-devel-5.11.10-200.fc33.x86_64
kernel-devel-5.11.11-200.fc33.x86_64
kernel-devel-5.11.9-200.fc33.x86_64
kernel-headers-5.11.11-200.fc33.x86_64
kernel-modules-5.11.10-200.fc33.x86_64
kernel-modules-5.11.11-200.fc33.x86_64
kernel-modules-5.11.9-200.fc33.x86_64
kernel-modules-extra-5.11.10-200.fc33.x86_64
kernel-modules-extra-5.11.11-200.fc33.x86_64
kernel-modules-extra-5.11.9-200.fc33.x86_64
kernel-srpm-macros-1.0-3.fc33.noarch
kernel-tools-5.11.11-200.fc33.x86_64
kernel-tools-libs-5.11.11-200.fc33.x86_64
libreport-plugin-kerneloops-2.14.0-15.fc33.x86_64

Now we want to remove the latest none working removing kernel, so in my case that would be: kernel-5.11.11-200.fc33.x86_64.

We now want to remove this kernel:

sudo dnf -y remove kernel-5.11.11-200.fc33.x86_64

Once complete, you can reinstall the kernel:

sudo dnf -y install kernel-5.11.11-200.fc33.x86_64

If you now reboot, hopefully having a working system on latest installed kernel.

Thanks Tom.

3 Likes

Many appreciation Mr. Doyle for your fast response and allocating some time for my post.

I couldn’t manage to deploy your guidance due to strange behavior.

Unfortunately, the situation seems to be a little bit complicated, in sense, that I already deployed many kernel version to keep for researching and studying purposes, so I have more than 10 version of it to choose from as shown below:

As many are suggesting to go with an easy approach and do a fresh Linux install after extracting my important data (if there was), yet I tend to get myself a full picture of what is happening behind the scenes of Linux Booting Process and it’s stages (read many books and articles regarding boot process). Therefore any kernel version I try to use it end up to the same issue, kind of strange to me.

Steps I have taken:
After many attempts in which I’ve tried my best to bypass that level of error and tried to get myself a terminal to do some sanity check, finally I’ve found an ambiguous approach buried deep in book called CompTIA Linux+ Study Guide Exam XK0-004, page 560, title Surviving a lost root password, so I deployed one of its suggested steps to press E key on boot menu to edit the grub, then look for (ro) kernel parameter and change it to rw init=/sysroot/bin/sh once you’ve done press Ctrl+X to boot the system, AND THAT WORKED when I’ve reached to emergency console prompt in which I’ve been looking for, so I can reach to the virtual file system.

Again I’ve discovered strange things! when I ls -lh the root (/) directory there were no /boot directory at all.

Blockquote

Hi,

So what happens if you try and reboot from - Fedora (5.10.7-200… (The 2nd on the list)? Are you able to boot from any of the kernels listed? If not you will to reinstall and restore from a backup up. Or if your setup has a separate home partition, you should be able to reinstall and keep your data.

Thanks Tom.

2 Likes

Any version that I tried to boot from stops at the same issue “kernel panic…” first image I shared.
My concern why in earth no /boot directory in first place

This may have corrupted your hdu/filesystem(s) (assuming a sdd). I would boot with a usb stick into rescue and check all filesystems on your system.

4 Likes

So what are the main steps to take after booting from LiveOS USB?

Basic steps can be found e.g. here: Chapter 19. Basic System Recovery
What exactly is the problem depends on how you installed the system, what you did with it and why you shut of the power for several times. You say you are a newbie and for a newbie there is a lot to learn. Just give it go, try some things, read the docs, use google and let us know about your progres,

1 Like
  1. I installed fedora 33 system via normal anaconda installer
  2. I’ve used it to (a) test and develop basic fedora UPDATER script and I’ve succeeded. (b) to study, research and understand Linux Booting Stages from BIOS/UEFI until login prompt
  3. Purposely conducted powering off the system to mimic Kernel Panic Senario add write down notes about it

Many respects to you Rene for referring me to the last link in which I’ve found one of my ambiguous questions pieces which the answer to it was, I quote:

“ Even if your file system is mounted, the default root partition while in rescue mode is a temporary root partition, not the root partition of the file system used during normal user mode (runlevel 3 or 5). If you selected to mount your file system and it mounted successfully, you can change the root partition of the rescue mode environment to the root partition of your file system”

With love

2 Likes