openzfs / zfs

OpenZFS on Linux and FreeBSD
https://openzfs.github.io/openzfs-docs
Other
10.42k stars 1.72k forks source link

zfs-dkms on Fedora 40 depends on too old a kernel #16377

Closed kbknapp closed 1 month ago

kbknapp commented 1 month ago

System information

Type Version/Name
Distribution Name Fedora
Distribution Version 40
Kernel Version 6.9.8
Architecture x86_64
OpenZFS Version 2.2.4

Describe the problem you're observing

zfs-dkms depends on kernel-devel < 6.8.999 but the current Fedora 40 kernel is 6.9.x resulting in kernel-devel-6.8.5 being installed.

Describe how to reproduce the problem

$ uname -r
6.9.8-200.fc40.x86_64

$ sudo dnf install zfs zfs-dracut                
Last metadata expiration check: 0:13:41 ago on Mon 22 Jul 2024 07:51:01 AM EDT.
Dependencies resolved.
============================================================================================================================================================================================================================================================================================
 Package                                                                Architecture                                                     Version                                                                     Repository                                                        Size
============================================================================================================================================================================================================================================================================================
Installing:
 kernel-devel                                                           x86_64                                                           6.8.5-301.fc40                                                              fedora                                                            20 M
 zfs                                                                    x86_64                                                           2.2.4-1.fc40                                                                zfs                                                              728 k
 zfs-dracut                                                             noarch                                                           2.2.4-1.fc40                                                                zfs                                                               18 k
Installing dependencies:
 zfs-dkms                                                               noarch                                                           2.2.4-1.fc40                                                                zfs                                                               31 M

Transaction Summary
============================================================================================================================================================================================================================================================================================
Install  4 Packages

Total size: 51 M
Total download size: 31 M
Installed size: 129 M
Is this ok [y/N]: ^COperation aborted.

$ sudo dnf install zfs zfs-dracut -x kernel-devel
Last metadata expiration check: 0:13:52 ago on Mon 22 Jul 2024 07:51:01 AM EDT.
Error: 
 Problem 1: package zfs-2.2.4-1.fc40.x86_64 from zfs requires zfs-kmod = 2.2.4, but none of the providers can be installed
  - package zfs-dkms-2.2.4-1.fc40.noarch from zfs requires kernel-devel <= 6.8.999, but none of the providers can be installed
  - conflicting requests
  - package kernel-devel-6.8.5-301.fc40.x86_64 from fedora is filtered out by exclude filtering
 Problem 2: package zfs-2.2.4-1.fc40.x86_64 from zfs requires zfs-kmod = 2.2.4, but none of the providers can be installed
  - package zfs-dracut-2.2.4-1.fc40.noarch from zfs requires zfs >= 2.2.4, but none of the providers can be installed
  - package zfs-dkms-2.2.4-1.fc40.noarch from zfs requires kernel-devel <= 6.8.999, but none of the providers can be installed
  - conflicting requests
  - package kernel-devel-6.8.5-301.fc40.x86_64 from fedora is filtered out by exclude filtering
(try to add '--skip-broken' to skip uninstallable packages)
tonyhutter commented 1 month ago

@kbknapp sorry it stopped building. F40 was originally released with the 6.8 kernel but they've since upgraded to 6.9. Weirdly, I could get one of the earlier F40 6.9.x kernels to build zfs-dkms, but looks like no more. We will fully support 6.9 in the upcoming zfs-2.2.5 release: https://github.com/openzfs/zfs/pull/16359

kbknapp commented 1 month ago

Yeah I got it building up through the 6.9.8 kernel (and just keeping kernel-devel-6.8.5 installed to keep the dep list happy), but at 6.9.9 it won't build any longer due to a UBSAN error.

jonhermansen commented 1 month ago

@kbknapp sorry it stopped building. F40 was originally released with the 6.8 kernel but they've since upgraded to 6.9. Weirdly, I could get one of the earlier F40 6.9.x kernels to build zfs-dkms, but looks like no more. We will fully support 6.9 in the upcoming zfs-2.2.5 release: #16359

@tonyhutter and team, thank you for your work. Fully up to date F40 compiled from your branch, scrubbed, and things seem OK.

aosan commented 1 month ago

ZFS 2.2.4 compiles for me without any problems with 6.9.12-200.fc40.x86_64.

I had to bump up the Linux-Maximum: in META to stop dnf updates from removing zfs and zfs-dkms.

Making them dnf protected packages should prevent them from dependency removals.

kbknapp commented 1 month ago

Just came back to say the same. I also tested letting dnf romove zfs and zfs-dkms but then just re-installing those two packages manually (which re-pulls in kernel-devel-6.8.5) which also worked fine.

tonyhutter commented 1 month ago

zfs-2.2.5 was released with 6.9 kernel support. Closing issue.

awused commented 3 weeks ago

I saw this and went to update, but Fedora is already on kernel 6.10. Arguably this should be reopened.

kbknapp commented 3 weeks ago

On Fedora with the latest kernel 6.10.3 everything builds fine with 2.2.5. The only negative is kernel-devel-6.8.5 is still pulled in, but that's a pretty minor issue.