XanMod is a free, open-source general-purpose Linux Kernel alternative to the stock kernel that is on Rocky Linux. It features custom settings and new features and is built to provide a responsive and smooth desktop experience, especially for new hardware.
Installing a third-party kernel may be for you for users seeking to have their system kernel up to date and not wanting to install kernels or use the testing/unstable repositories manually.
Currently, the XanMod LTS kernel is supported and not the latest bleeding-edge using the rmnscnce/kernel-xanmod.
For more information on XanMod Kernel before installing, visit the XanMod Kernel features information page.
In the following tutorial, you will learn how to install the latest XanMod Kernel on your Rocky Linux 8 server or workstation desktop.
Table of Contents
Update Rocky Linux System
Update your Rocky Linux operating system to make sure all existing packages are up to date:
sudo dnf upgrade --refresh -y
Install XanMod Kernel LTS
The first task is to enable the Copr repository rmnscnce/kernel-xanmod. In your terminal, use the following command.
sudo dnf copr enable rmnscnce/kernel-xanmod -y
With the Copr repository now enabled, you can install the XanMod Kernel.
sudo dnf in kernel-xanmod-lts
Type Y, then press the ENTER KEY to proceed.
During the installation, you will be prompted to import the GPG key to verify the authenticity of the installed packages.
Type Y, then press the ENTER KEY to complete the installation.
Once installed, you need to reboot your PC, which you can quickly do in the terminal window.
Once you have returned to your system, verify the installation.
Remember, this version number will be different in time, and the XanMod kernel receives updates constantly.
Update XanMod Kernel LTS
To keep the Linux kernel you installed with XanMod up to date, you will run the standard dnf update and upgrade commands.
To check for updates.
sudo dnf update
If an upgrade is available.
sudo dnf upgrade
Alternatively, users should be using the upgrade –refresh command, which is faster and more accurate.
sudo dnf upgrade --refresh
Remove (Uninstall) XanMod Kernel LTS
To remove XanMod Kernel, use the following command.
sudo dnf remove kernel-xanmod-lts
However, you will notice after rebooting that the XanMod kernel remains. To remove it in full from your system, you need to disable the repository, re-install the original kernel.
First, disable the Copr repository that XanMod was installed from.
sudo dnf copr disable rmnscnce/kernel-xanmod -y
Next, re-install the default kernel packages.
sudo dnf reinstall kernel*
Type Y, then the ENTER KEY to proceed and re-install the kernel.
Next, reboot your PC.
Now back in your system, recheck the kernel version installed.
Next, confirm that the original kernels are installed only using the rpm -qa command.
rpm -qa | grep `uname -r`
Congratulations, you restored the original default system kernel and removed XanMod Kernel entirely.
Comments and Conclusion
In the tutorial, you have learned how to install XanMod on Rocky Linux 8 and how to remove and re-install the default kernel.
Overall, the LTS edition of XanMod is great for Rocky Linux environments that would benefit from an upgraded kernel without resorting to going far too down the chain to the latest bleeding stable kernel that may bring some inconsistencies to your stable system.