This post will share a solution on how you can fix kernel panic in Ubuntu. after I updated it from Ubuntu 20 to 22. I encountered this problem when I tried to update my desktop running Ubuntu 20 to Ubuntu 22 and as always initially, I thought I would take the nuclear route and just wipe the ssd and reinstall Ubuntu. Then I realised that I would have to configure that machine all over again, generate ssh keys, customise the bashrc file etc etc. Now it just so happens that I hate reconfiguring my machine more than I love formatting my drive and doing a clean install of a Linux distro. Hence I decided to look online for a solutions and try some of the solutions I come across. Luckily enough, I found a solution, which I will share in this post. It was not that hard really, it was quite straight-forward, it was just the persistence of being on the lookout for a solution and resisting the urge to format the drive and do a reinstall.

How to fix Kernel Panic in Ubuntu 22

After you run into this issue and do an online search, a lot of the articles that you find will talk about how to fix it in Gentoo among others. Now these results may present a solution that may not apply to Ubuntu. To fix Kernel panic in Ubuntu was a lot simpler in my case at least. I simply had to follow these steps

  1. Start the computer
  2. Click Advanced options after which
  3. I saw 4 options which looking something like linux-image-generic with the version number
  4. I selected an option 3 or the one with the lower number which was the older kernel
  5. After that Ubuntu boots and I am in Ubuntu via the older kernel
  6. Launch the terminal and run the following commands
sudo apt-get update
sudo apt-get upgrade
sudo apt-get upgrade linux-image-generic
(the last command is optional)

Now the new Kernel will be downloaded, restart the computer after the process finishes and the system will assign the new kernel during boot, hence no kernel panic.

Summary

In this post, you saw how to fix the Kernel panic problem in Ubuntu 22. As you can see, the key here is not do as the error suggests: Panic! Instead just stay calm and know that there is a solution out there and it’s just a matter of time till you find it.

If you find any of my posts useful and want to support me, you can buy me a coffee 🙂

https://www.buymeacoffee.com/bhumansoni

Have a read of some of my posts on AWS

Deploy NodeJS, Typescript app on AWS Elastic beanstalk – (mydaytodo.com)

How to deploy spring boot app to AWS & serve via https – My Day To-Do (mydaytodo.com)

or some of my posts on Javascript …

What is Javascript event loop? – My Day To-Do (mydaytodo.com)

How to build a game using Vanilla Javascript – My Day To-Do (mydaytodo.com)

Vanilla Javascript: Create Radio Buttons (How-To) – Bhuman Soni (mydaytodo.com)

Categories: unix

0 Comments

Leave a Reply

Avatar placeholder
Verified by MonsterInsights