How to install kernel in Ubuntu?

First, check your current kernel version:

uname -r

If you want to upgrade or manually install a new kernel, one safe method is using the official Ubuntu Mainline Kernel builds.

To download and install a newer kernel version manually:

Pick the version you want (e.g., v6.8.x). Right-click the .deb links for your architecture (usually amd64) and copy the link. Now use wget to download the packages. For example:

wget https://kernel.ubuntu.com/~kernel-ppa/mainline/v6.8.2/amd64/linux-headers-6.8.2-060802-generic_6.8.2-060802.202404031234_amd64.deb
wget https://kernel.ubuntu.com/~kernel-ppa/mainline/v6.8.2/amd64/linux-image-6.8.2-060802-generic_6.8.2-060802.202404031234_amd64.deb
wget https://kernel.ubuntu.com/~kernel-ppa/mainline/v6.8.2/amd64/linux-modules-6.8.2-060802-generic_6.8.2-060802.202404031234_amd64.deb

Then install them all together:

sudo dpkg -i *.deb

Once installed, reboot your system:

sudo reboot

After reboot, verify the kernel version:

uname -r

If the new version is shown, the installation was successful.

To remove older kernels later (optional):

dpkg -l | grep linux-image

Then use sudo apt remove to delete unnecessary old versions carefully.

Alternatively, you can use the mainline tool to install new kernels more easily:

First, add the repository:

sudo add-apt-repository ppa:cappelikan/ppa
sudo apt update
sudo apt install mainline -y

Launch it:

mainline

This tool gives you a GUI to pick and install any available kernel version directly.

Share:

More Posts

How to Install Maven on macOS 2025

What you will read?1 Check for Java Installation2 Install Homebrew (If Not Installed)3 Install Maven via Homebrew4 Verify Environment Variables (Optional)5 Create a Sample Maven

How to Use Google SMTP Server

What you will read?1 Step 1: Enable SMTP Access in Gmail2 Step 2: Secure Connection with TLS3 Step 3: Send an Email via SMTP4 Step

how to install wine on RHEL

What you will read?1 Check RHEL version and CPU architecture2 Update system and install base tools3 Verify subscription and enable CodeReady Builder4 Enable EPEL repository5

Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments