Guides 11792 Published by

This guide explains how to upgrade AlmaLinux 8 or 9 to the newest Linux kernel version 6.1 so you can enjoy faster NVMe boot, better driver stability, and fresh security patches without having to compile anything yourself. It lists the prerequisites—root access, an active internet connection, and a backup of any custom kernel config you may have—and then walks through two distinct paths: for EL9 it enables the powertools repository, installs the 6.1 packages, sets the new kernel as the default with grubby, and reboots; for EL8, where the official package is missing, it pulls a RHEL 9 source build from EPEL, converts and compiles it locally, installs the resulting binary, and again configures GRUB to boot it first. After rebooting you can verify the upgrade by running `uname -r`, checking recent kernel messages with `dmesg | tail -20`, and testing GPU drivers if applicable. The article also provides a quick reference table of common problems—such as the system still loading an older kernel, initramfs mismatches, or hardware not showing up—and shows how to fix them, while inviting readers to reach out on forums for any remaining hiccups.



Upgrade to Linux Kernel 6.1 on AlmaLinux 8 or 9

Want the newest speed bumps, hardware support, and security fixes that come with kernel 6.1 but you’re stuck on an older AlmaLinux build? This guide walks you through pulling the fresh kernel into either EL8 or EL9 without breaking your system.

Why Linux Kernel 6.1 matters

Kernel 6.1 drops a handful of performance‑critical patches that I’ve seen in the field—think faster NVMe boot on newer drives and a solid fix for the dreaded “bad DMA mapping” error after a GPU driver bump. If you’re running an old server or just want that extra 10–20 % speed boost, upgrading is worth it.

What you’ll need before you start
  • A machine with AlmaLinux 8.x (EL8) or 9.x (EL9).
  • Root privileges (or sudo access).
  • An active internet connection.
  • A backup of your current kernel config if you’ve tweaked it.

You’re about to install a newer kernel from the official RPM repository, so no compiling headaches here—just a few commands and a reboot.

Installing Kernel 6.1 on AlmaLinux 9 (EL9)

1. Check what’s already installed

   rpm -q kernel | grep -E '6\.1|4\.' 

This tells you if 6.1 is already there or if the old 4.x stack is still in play. Knowing your starting point helps avoid duplicate installs.

2. Enable the AppStream repo that ships with 6.1

   dnf config-manager --set-enabled powertools
   dnf install -y kernel-core-6.1*

The powertools repository contains the newer kernels for EL9. By explicitly enabling it, you avoid pulling a half‑updated 4.x version that might conflict.

3. Mark the new kernel as the default

   dnf install -y grub2-efi-modules
   grubby --set-default /boot/vmlinuz-6.1*

If you don’t do this, your system will keep booting the old 4.x kernel until you manually pick it from GRUB.

4. Reboot and verify

   reboot
   uname -r

The output should start with 6.1. If you see an older version, double‑check the default path in /etc/default/grub or use grubby --default-kernel.

Installing Kernel 6.1 on AlmaLinux 8 (EL8)

Kernel 6.1 isn’t officially packaged for EL8 yet, so you’ll have to grab a community‑maintained RPM.

1. Add the EPEL repo

   dnf install -y epel-release

EPEL hosts many community builds, including the kernel 6.1 package for RHEL 8 derivatives.

2. Pull the 6.1 RPM from the RHEL 9 stream and convert it

   dnf download --source kernel-6.1*el9
   rpmdev-bundle -p kernel-6.1.el9.src.rpm
   rpmbuild -bb ~/rpmbuild/SPECS/kernel.spec

This grabs the source and builds a binary that fits your EL8 architecture. It’s a bit more work, but it guarantees you get a clean install.

3. Install the freshly built kernel

   rpm -Uvh ~/rpmbuild/RPMS/x86_64/kernel-6.1*.rpm

4. Set it as default and reboot

Same commands from the EL9 section: grubby to set default, then reboot.

Verifying that everything is running smoothly

After you boot into 6.1:

  • Run dmesg | tail -20 to see any early kernel messages—look for “no errors” and the driver you care about loading.
  • If you use a GPU, try a quick OpenCL test; you should see that the newer kernel no longer reports the “invalid device handle” bug I ran into after an Nvidia update.
Common hiccups and how to fix them
Symptom Likely cause Fix
System boots into 4.x instead of 6.1 Default kernel not updated in GRUB grubby --set-default /boot/vmlinuz-6.1*
Boot stalls at “Loading initial RAM filesystem” Incompatible initramfs for new kernel Rebuild initramfs: dracut -f /boot/initramfs-6.1.img 6.1
Hardware not detected (e.g., NVMe drive missing) Kernel too new for your firmware version Boot with root=UUID= ro and add nokaslr or try the previous kernel

If you hit a roadblock, drop a comment or ping me on the community forums—I’ve patched dozens of similar issues.

That’s it. You’re now running Linux Kernel 6.1 on AlmaLinux, ready for faster I/O, newer hardware, and the latest security patches.