How to install Linux kernel 6.0 on Ubuntu 22.04

Jack Wallen walks you through two different methods to install the latest Linux kernel on Ubuntu 22.04.

Monitor close-up function source code.  IT technology abstract background.  software source code.
Image: Maximusdn/Adobe Stock

The Linux 6.0 kernel is the latest version for the operating system and includes the usual amount of bug fixes, performance improvements, enhancements and support for new hardware. However, it will still be some time before most Linux distributions ship with the latest kernel from creator Linus Torvalds.

Fear not: I will show you how to get this new kernel working on your Ubuntu 22.04 deployments.

SEE: 40+ Open Source and Linux Terms You Need to Know (TechRepublic Premium)

One thing to note is that you really should wait until the kernel for your distribution of choice has been released to the repositories. By holding back, you ensure that the maintainers of your distribution have had time to polish everything so that everything works exactly as expected.

Still, I know that some – like myself – can’t wait to test the shiny new version of kernel maintainers. To that end, I have the steps you need to get this new kernel working.

What you need to install kernel 6.0 on Ubuntu 22.04

First, you’ll need a running instance of Ubuntu 22.04, although I would advise against doing this on production machines. Install it on test machines instead to make sure everything works as expected. You also need a user with sudo privileges. Believe it or not, it is.

How to update Ubuntu

The first thing we need to do is a full upgrade. Login to your Ubuntu instance, open a terminal window and enter the command:

sudo apt-get update && sudo apt-get full-upgrade -y

The command above updates apt and then runs the full upgrade. Once this is complete, restart the system and log in again.

How to upgrade to kernel 6.0

The first method we will use is to manually download the necessary files and install them using dpkg. Here are the files you want to download and the commands to do it:

wget https://kernel.ubuntu.com/~kernel-ppa/mainline/v6.0/amd64/linux-image-unsigned-6.0.0-060000-generic_6.0.0-060000.202210022231_amd64.deb

wget https://kernel.ubuntu.com/~kernel-ppa/mainline/v6.0/amd64/linux-modules-6.0.0-060000-generic_6.0.0-060000.202210022231_amd64.deb
wget https://kernel.ubuntu.com/~kernel-ppa/mainline/v6.0/amd64/linux-headers-6.0.0-060000-generic_6.0.0-060000.202210022231_amd64.deb
wget https://kernel.ubuntu.com/~kernel-ppa/mainline/v6.0/amd64/linux-headers-6.0.0-060000_6.0.0-060000.202210022231_all.deb

To install these files, now enter the command:

sudo dpkg -i *.deb

You may get an error message that the system cannot create the modules. If that’s the case, solve it with:

sudo apt-get install gcc make perl -y

Once the installation is complete, reboot the computer and check the kernel with:

uname -r

You should see that the system is now running kernel 6.0.

The second method uses a third-party PPA, which means the kernel is updated using the built-in package manager instead of having to be manually updated as above.

To add the new repository, enter the command:

sudo add-apt-repository ppa:cappelikan/ppa

Next update apt with:

sudo apt update

Finally, install the kernel with the command:

sudo apt install mainline -y

After the installation is complete, reboot, log in again and enter the command uname -r to see that your system is now powered by the 6.0 kernel.

Congratulations: you’ve taken your Linux machine to the next level of performance and functionality.

Subscribe to TechRepublic’s How To Make Tech Work on YouTube for the latest tech advice for business professionals from Jack Wallen.

Leave a Reply

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