Linux kernel vanilla repositories for Fedora Linux
The kernel vanilla copr repositories allow you to quickly, comfortably, and cleanly install the latest upstream Linux kernels on Fedora Linux. The packaged kernels from series like ‘mainline’ and ‘stable’ are ideal for both quick tests and regular day-to-day use.
To install a kernel from these repositories, first chose which copr to use with the help of the following table; then enable the chosen copr and update your system. The section right below the table explains these steps in more detail.
Linux kernels offered in the six coprs
@kernel-vanilla copr | description | target users | example version sequence |
---|---|---|---|
fedora | Vanilla kernels from the stable series the latest Fedora Linux currently uses. | Anyone wanting to use the latest release from the kernel series Fedora Linux currently uses – for example to check if a bug that happens with Fedora's kernel occurs with the latest upstream version from the same kernel series. | …, 6.0.18, 6.0.19, 6.1.5, 6.1.6, … |
stable | The latest stable kernel according to the frontpage of kernel.org; this repo thus won't ship mainline releases like 6.1 and only jumps to a newer series once its first stable release (e.g. 6.1.1) is published. | Anyone who wants the latest Linux stable kernel. | …, 6.0.14, 6.0.15, 6.1.1, 6.1.2, 6.1.3, … |
stable-rc | Pre-releases of the next stable release. | Anyone who wants to help testing future Linux stable kernels. | …, 6.0.14, 6.0.15-rc1, 6.0.15, 6.1.1-rc1, 6.1.1, … |
mainline-wo-mergew | The latest mainline kernel, either built from a proper release, a pre-release (aka "rc kernel"), or a git snapshot – albeit the latter only after -rc1 was released. | Anyone who normally wants the latest mainline kernel, but wants to play it a bit safer by avoiding mainline during its 'merge windows' – that's the phase at the beginning of each development cycle where the bulk of changes (~85 percent) including all riskier ones are merged for the next mainline release, before its first pre-release (e.g. "6.x-rc1") is published. | …, 6.1-rc8-20221211, 6.1, 6.1.1-rc1, 6.1.1, 6.2-rc1, 6.2-rc1-20221226, 6.2-rc1-20221227, … |
mainline | Mainline kernels, either built from a proper release, a pre-release (aka "rc kernel"), or a git snapshot. | Anyone who wants to run a kernel built from the the latest Linux codebase. | …, 6.1-rc8-20221211, 6.1, 6.2-rc0-20221213, 6.2-rc0-20221214, 6.2-rc0-20221215, … |
next | Linux-next kernels. | Anyone who wants to run linux-next or test if the changes slated for inclusion in the next mainline cycle fix a problem. | …, 6.1-0.0.next.20221210, 6.1-0.0.next.20221211,6.1-0.0.next.20221213, … |
Note: only the next copr is stand-alone; all the others include the repositories from coprs mentioned higher in the list as a runtime dependency. Users of the ‘stable-rc’ copr thus will receive packages from the ‘stable’ or ‘fedora’ coprs when they ship kernel packages which dnf will consider newer; this will ensure users of stable-rc won’t be stuck on a -rc kernel with known problems that were fixed between the release of a -rc and the final version.
|
How to install a vanilla kernel from these repositories
If you’re on a x86-64 (aka AMD64) system, first run mokutil --sb-state
to check whether UEFI Secure Boot is active on your system. If that’s the case you have to turn it off either in your BIOS Setup or through a process initiated with mokutil --disable-validation
; do not omit this, as the kernels from these repositories won’t boot otherwise, because they are not signed with a key typical x86-64 systems trust.
Now enable one of the kernel vanilla coprs and update your system. The following commands for example will install the latest mainline kernel:
sudo dnf -y copr enable @kernel-vanilla/mainline sudo dnf upgrade 'kernel*'
In case you want to install just one vanilla kernel for a quick test, run sudo dnf copr remove @kernel-vanilla/mainline
right afterwards to disabled the copr again. Once you finished your tests you furthermore want to uninstall the kernel as explained in the next section, as dnf otherwise won't install newly released Fedora kernels for days or weeks to come, as those have a lower version number.
In case you want to use the copr regularly, consider advising dnf to check them for new packages more often than usual – for example by running the following command, which tells dnf to query frequently updated coprs every hour and others every four hours:
sudo sed -i 's!baseurl=https://download.copr.fedorainfracloud.org/results/@kernel-vanilla/\(mainline\|stable-rc\|next\).*!&\nmetadata_expire=1h!g; s!baseurl=https://download.copr.fedorainfracloud.org/results/@kernel-vanilla/\(stable\|fedora\)/.*!&\nmetadata_expire=4h!g;' /etc/yum.repos.d/_copr:copr.fedorainfracloud.org:group_kernel-vanilla:*.repo
How to remove the kernel vanilla repositories and uninstall kernels installed from them
Disable any kernel vanilla coprs you enabled and ensure you have the latest official kernel installed fedora offers:
dnf copr list | grep 'group_kernel-vanilla' | xargs -r sudo dnf copr remove sudo dnf distrosync kernel
At this step it is highly recommended to boot into the latest official Fedora kernel; to do so, chose the top-most one from the boot menu that does not have 'vanilla' in the name.
Now remove all kernels installed from the kernel vanilla coprs:
rpm -qa 'kernel*' | grep '.vanilla' | xargs -r sudo dnf remove
From now on your system will behave like one that never had these repositories enabled or kernels installed from it.
How vanilla kernels compare to Fedora’s
Most of the time these kernels will work roundabout as well and secure as Fedora’s. Sometimes though the kernels from these repositories will work better, as they contain drivers or security fixes that haven’t reached the kernel used by Fedora Linux yet; other times it's the other way around, as Fedora sometimes includes fixes that upstream hasn't picked up yet. But those differences rarely matter much.
Some coprs will be empty and look abandoned
Please be aware that two or three of the coprs will often look outdated, abandoned, or empty when you check copr’s web interface or look straight at the package repositories. But be assured, most likely everything is well and working as intended. It will look like that when the most recent build suitable for users of that copr is found in one of the other copr included as a runtime dependency. The footnote in above table explains this in more details.
Linux kernel versions currently offered
A repostatus file shows what the repositories currently provide. Alternatively, execute the following script to query the latest packages locally:
dists=(37 38 39 rawhide) dnf clean all > /dev/null for repo in fedora stable{,-rc} mainline{-wo-mergew,} next; do [[ ${repo} =~ (fedora|next) ]] && unset repostring repostring="${repostring} --repofrompath=kvr-${repo},https://download.copr.fedorainfracloud.org/results/@kernel-vanilla/${repo}/fedora-\${distro}-x86_64/" for distro in ${dists[*]} ; do queryresult="$(eval dnf repoquery ${repostring} --disablerepo=* --enablerepo=kvr-* --latest-limit=1 -q kernel --arch x86_64 --qf '%{version}-%{release}')" printf '%-20s %-10s %s\n' "${repo}" "${distro}" "${queryresult:-lookup failed}" done done
Developers behind the effort and point of contact
The Linux kernel vanilla copr repositories for Fedora are maintained by Thorsten Leemhuis (aka "knurd"); they are build using a RPM spec file that is nearly identical to the one used to build Fedora’s kernel. Note though, maintainers of the latter are not involved in the maintenance of these repositories.
For any feedback or questions regarding the kernel vanilla repositories contact Thorsten Leemhuis (aka "knurd").
What’s the goal of these repositories? And are these kernels as good as Fedora’s?
These and many other questions are answered in the FAQ about the Linux kernel vanilla repositories for Fedora Linux.