The kernel is the core and most essential component of Linux operating systems. It provides an interface between software applications and computer hardware. It is responsible for managing I/O disks, filesystems, CPU, and processes. The kernel is responsible for managing resources as efficiently as possible. The community of kernel Developers builds and deploys patches and updates to the Linux kernel to roll out security updates, bug fixes, and new functionality. If you are using a Linux operating system, it is a good idea to update the kernel to the latest version.
In this post, we will show you how to install the latest Linux kernel on Ubuntu 20.04.
- A server running Ubuntu 20.04 on the Atlantic.Net Cloud Platform
- A root password configured on your server
Step 1 – Create Atlantic.Net Cloud Server
First, log in to your Atlantic.Net Cloud Server. Create a new server, choosing Ubuntu 20.04 as an operating system with at least 1GB RAM. Connect to your Cloud Server via SSH and log in using the credentials highlighted at the top of the page.
Step 2 – Update and Upgrade the System
First, check your current operating system using the following command:
You will get your operating system version in the following output:
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.3 LTS
Next, install the required dependencies with the following command:
apt-get install gnupg2 wget -y
Next, update and upgrade all system packages to the latest version.
apt-get update -y
apt-get upgrade -y
Once all the packages are upgraded, restart your system to apply the changes:
Step 3 – Check Current Kernel Version
Next, check the currently installed kernel version with the following command:
You will get the current kernel version in the following output:
Step 4 – Download the Linux Kernel Installation Script
Next, download the Linux kernel installation script on your system. This script will allow us to install the latest kernel on Linux.
You can download it using the following command:
Once the download is complete, you will get the following output:
--2022-04-13 15:35:52-- https://raw.githubusercontent.com/pimlie/ubuntu-mainline-kernel.sh/master/ubuntu-mainline-kernel.sh
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 184.108.40.206, 220.127.116.11, 18.104.22.168, ...
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|22.214.171.124|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 26474 (26K) [text/plain]
Saving to: ‘ubuntu-mainline-kernel.sh’
ubuntu-mainline-kernel.sh 100%[=================================================================>] 25.85K --.-KB/s in 0.001s
2022-04-13 15:35:52 (26.9 MB/s) - ‘ubuntu-mainline-kernel.sh’ saved [26474/26474]
Next, set the execution permissions to the downloaded script with the following command:
chmod +x ubuntu-mainline-kernel.sh
Step 5 – Install the Latest Kernel Version
Now, run the Linux kernel installation script to install the latest kernel on your system.
You will be asked to install the latest kernel version as shown below:
Finding latest version available on kernel.ubuntu.com
Latest version is: v5.17.2, continue? (y/N)
Press the y key to start the installation. Once the latest kernel version is installed, you will get the following output:
Will download 6 files from kernel.ubuntu.com:
Downloading amd64/linux-headers-5.17.2-051702-generic_5.17.2-051702.202204081338_amd64.deb: 100%
Downloading amd64/linux-headers-5.17.2-051702_5.17.2-051702.202204081338_all.deb: 100%
Downloading amd64/linux-image-unsigned-5.17.2-051702-generic_5.17.2-051702.202204081338_amd64.deb: 100%
Downloading amd64/linux-modules-5.17.2-051702-generic_5.17.2-051702.202204081338_amd64.deb: 100%
Downloading amd64/CHECKSUMS: 100%
Downloading amd64/CHECKSUMS.gpg: 100%
Importing kernel-ppa gpg key ok
Signature of checksum file has been successfully verified
Checksums of deb files have been successfully verified with sha256sum
Installing 4 packages
Cleaning up work folder
Step 6 – Restart the System
After the latest kernel installation, you will need to restart your system to boot the system from the newly installed kernel.
Step 7 – Verify the Latest Kernel Version
After the successful restart, run the following command to check the newly installed kernel version:
You should see the following output:
In this post, we explained how to install the latest Kernel version on Ubuntu 20.04. You can now easily upgrade or install the latest Kernel version to your server. Try it on dedicated hosting from Atlantic.Net!