Kernel, the central component of an operating system, plays a critical role in managing computer operations and hardware. It acts as a bridge between applications and hardware-level data processing, facilitating inter-process communication and system calls. In this article, we will explore the step-by-step process of installing Kernel 6.x on Rocky Linux 9.
Prerequisites
Before we begin, make sure you have the following:
- Access to the Rocky Linux command line terminal.
- Root privileges or Sudo privileges.
Step 1: Find the Current Kernel Version
To determine the current version of the kernel your system is running, use the uname
command:
uname -sr
Output:
[root@vps ~]# uname -sr Linux 5.14.0-162.6.1.el9_1.0.1.x86_64
Step 2: Enable the ELRepo Repository
The ELRepo repository provides additional kernel packages for CentOS and its derivatives, including Rocky Linux. To enable the repository, follow these steps:
- Import the public key and install the ELRepo RPM package:
rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org dnf install https://www.elrepo.org/elrepo-release-9.el9.elrepo.noarch.rpm
Output:
[root@vps ~]# rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
[root@vps ~]# dnf install https://www.elrepo.org/elrepo-release-9.el9.elrepo.noarch.rpm
Rocky Linux 9 - BaseOS 652 kB/s | 1.7 MB 00:02
Rocky Linux 9 - AppStream 14 MB/s | 6.4 MB 00:00
Rocky Linux 9 - Extras 8.9 kB/s | 8.3 kB 00:00
elrepo-release-9.el9.elrepo.noarch.rpm 32 kB/s | 12 kB 00:00
Dependencies resolved.
===============================================================================
Package Arch Version Repository Size
===============================================================================
Installing:
elrepo-release noarch 9.1-1.el9.elrepo @commandline 12 k
Transaction Summary
===============================================================================
Install 1 Package
Total size: 12 k
Installed size: 5.0 k
Is this ok [y/N]: y
Downloading Packages:
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Preparing : 1/1
Installing : elrepo-release-9.1-1.el9.elrepo.noarch 1/1
Verifying : elrepo-release-9.1-1.el9.elrepo.noarch 1/1
Installed:
elrepo-release-9.1-1.el9.elrepo.noarch
Complete!
dnf --disablerepo="*" --enablerepo="elrepo-kernel" list available
Output:
[root@vps ~]# dnf --disablerepo="*" --enablerepo="elrepo-kernel" list available
Last metadata expiration check: 0:06:19 ago on Tue 03 Jan 2023 01:29:37 PM UTC.
Available Packages
bpftool.x86_64 6.1.2-1.el8.elrepo elrepo-kernel
elrepo-release.noarch 8.3-1.el8.elrepo elrepo-kernel
kernel-lt.x86_64 5.4.228-1.el8.elrepo elrepo-kernel
kernel-lt-core.x86_64 5.4.228-1.el8.elrepo elrepo-kernel
kernel-lt-devel.x86_64 5.4.228-1.el8.elrepo elrepo-kernel
kernel-lt-doc.noarch 5.4.228-1.el8.elrepo elrepo-kernel
kernel-lt-headers.x86_64 5.4.228-1.el8.elrepo elrepo-kernel
kernel-lt-modules.x86_64 5.4.228-1.el8.elrepo elrepo-kernel
kernel-lt-modules-extra.x86_64
5.4.228-1.el8.elrepo elrepo-kernel
kernel-lt-tools.x86_64 5.4.228-1.el8.elrepo elrepo-kernel
kernel-lt-tools-libs.x86_64 5.4.228-1.el8.elrepo elrepo-kernel
kernel-lt-tools-libs-devel.x86_64
5.4.228-1.el8.elrepo elrepo-kernel
kernel-ml-devel.x86_64 6.1.2-1.el8.elrepo elrepo-kernel
kernel-ml-doc.noarch 6.1.2-1.el8.elrepo elrepo-kernel
kernel-ml-headers.x86_64 6.1.2-1.el8.elrepo elrepo-kernel
kernel-ml-modules-extra.x86_64
6.1.2-1.el8.elrepo elrepo-kernel
kernel-ml-tools.x86_64 6.1.2-1.el8.elrepo elrepo-kernel
kernel-ml-tools-libs.x86_64 6.1.2-1.el8.elrepo elrepo-kernel
kernel-ml-tools-libs-devel.x86_64
6.1.2-1.el8.elrepo elrepo-kernel
perf.x86_64 6.1.2-1.el8.elrepo elrepo-kernel
python3-perf.x86_64 6.1.2-1.el8.elrepo elrepo-kernel
Step 3: Install the Kernel
Now that the ELRepo repository is enabled, you can proceed with installing the latest mainline stable kernel. Use the following command:
dnf --enablerepo=elrepo-kernel install kernel-ml
Output:
[root@vps ~]# dnf --enablerepo=elrepo-kernel install kernel-ml
ELRepo.org Community Enterprise Linux Repository - el8 210 kB/s | 239 kB 00:01
Dependencies resolved.
=============================================================================================================================
Package Architecture Version Repository Size
=============================================================================================================================
Installing:
kernel-ml x86_64 6.1.2-1.el8.elrepo elrepo-kernel 98 k
Installing dependencies:
kernel-ml-core x86_64 6.1.2-1.el8.elrepo elrepo-kernel 34 M
kernel-ml-modules x86_64 6.1.2-1.el8.elrepo elrepo-kernel 30 M
Transaction Summary
=============================================================================================================================
Install 3 Packages
Total download size: 64 M
Installed size: 100 M
Is this ok [y/N]: y
Downloading Packages:
(1/3): kernel-ml-6.1.2-1.el8.elrepo.x86_64.rpm 172 kB/s | 98 kB 00:00
(2/3): kernel-ml-modules-6.1.2-1.el8.elrepo.x86_64.rpm 9.2 MB/s | 30 MB 00:03
(3/3): kernel-ml-core-6.1.2-1.el8.elrepo.x86_64.rpm 8.2 MB/s | 34 MB 00:04
-----------------------------------------------------------------------------------------------------------------------------
Total 15 MB/s | 64 MB 00:04
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Preparing : 1/1
Installing : kernel-ml-core-6.1.2-1.el8.elrepo.x86_64 1/3
Running scriptlet: kernel-ml-core-6.1.2-1.el8.elrepo.x86_64 1/3
Installing : kernel-ml-modules-6.1.2-1.el8.elrepo.x86_64 2/3
Running scriptlet: kernel-ml-modules-6.1.2-1.el8.elrepo.x86_64 2/3
Installing : kernel-ml-6.1.2-1.el8.elrepo.x86_64 3/3
Running scriptlet: kernel-ml-core-6.1.2-1.el8.elrepo.x86_64 3/3
Running scriptlet: kernel-ml-6.1.2-1.el8.elrepo.x86_64 3/3
Verifying : kernel-ml-6.1.2-1.el8.elrepo.x86_64 1/3
Verifying : kernel-ml-core-6.1.2-1.el8.elrepo.x86_64 2/3
Verifying : kernel-ml-modules-6.1.2-1.el8.elrepo.x86_64 3/3
Installed:
kernel-ml-6.1.2-1.el8.elrepo.x86_64 kernel-ml-core-6.1.2-1.el8.elrepo.x86_64
kernel-ml-modules-6.1.2-1.el8.elrepo.x86_64
Complete!
Step 4: Verify the Kernel Version
By default, the system will set the newly installed kernel as the default version to use and boot with. You can verify this by running the following command:
grubby --default-kernel
Once confirmed, reboot the system to boot with the latest kernel installed. You can further verify the kernel version by running the uname
command:
uname -r
Output:
[root@vps ~]# uname- r 6.1.2-1.el8.elrepo.x86_64
Congratulations! You have successfully installed Kernel 6.x on Rocky Linux 9. Your system is now equipped with the latest stable kernel, providing improved performance, security, and compatibility.
To take full advantage of the new kernel, consider exploring its features and optimizations specific to your use case. Additionally, ensure that your applications and drivers are compatible with the installed kernel version.
By staying up to date with the latest kernel releases, you can benefit from the continuous advancements and enhancements in the Linux ecosystem.
Conclusion
In this article, we explored the process of installing Kernel 6.x on Rocky Linux 9. We began by finding the current kernel version, enabled the ELRepo repository, installed the latest mainline stable kernel, and verified the installation. Keeping your kernel up to date is crucial for optimal performance and security on your Linux system.
If you’re looking for reliable Linux SSD VPS hosting services, consider Shape.host. They offer scalable and secure cloud hosting solutions, empowering businesses with efficient and high-performing infrastructure. Upgrade your hosting experience with Shape.host and experience the power of cutting-edge technology.
So, go ahead and leverage the capabilities of Kernel 6.x on Rocky Linux 9 to unlock the full potential of your Linux system.