Cannot install ZFS

So, this is the mission:
I have a ZFS-formatted disk (one half of a ZFS mirror) on an NVME “disk” that I want to read data of. The “disk” will be attached via USB - Adapter from icybox.
I thought to myself “easy task, let’s got and install zfs and be happy”. Does not work:

yay -S zfs
Sync Explicit (1): zfs-dkms-2.2.6-1
[sudo] password for shihatsu: 
resolving dependencies...
looking for conflicting packages...

Package (2)            New Version  Net Change  Download Size

endeavouros/zfs-utils  2.2.6-3        9,20 MiB       2,45 MiB
endeavouros/zfs-dkms   2.2.6-1       18,78 MiB       2,42 MiB

Total Download Size:    4,87 MiB
Total Installed Size:  27,98 MiB

:: Proceed with installation? [Y/n] 
:: Retrieving packages...
 zfs-dkms-2.2.6-1-any                                                                                                                                               2,4 MiB  11,7 MiB/s 00:00 [-----------------------------------------------------------------------------------------------------------------------] 100%
 zfs-utils-2.2.6-3-x86_64                                                                                                                                           2,5 MiB  5,98 MiB/s 00:00 [-----------------------------------------------------------------------------------------------------------------------] 100%
 Total (2/2)                                                                                                                                                        4,9 MiB  11,6 MiB/s 00:00 [-----------------------------------------------------------------------------------------------------------------------] 100%
(2/2) checking keys in keyring                                                                                                                                                                [-----------------------------------------------------------------------------------------------------------------------] 100%
(2/2) checking package integrity                                                                                                                                                              [-----------------------------------------------------------------------------------------------------------------------] 100%
(2/2) loading package files                                                                                                                                                                   [-----------------------------------------------------------------------------------------------------------------------] 100%
(2/2) checking for file conflicts                                                                                                                                                             [-----------------------------------------------------------------------------------------------------------------------] 100%
:: Running pre-transaction hooks...
(1/1) Performing snapper pre snapshots for the following configurations...
==> root: 6977
:: Processing package changes...
(1/2) installing zfs-utils                                                                                                                                                                    [-----------------------------------------------------------------------------------------------------------------------] 100%
Optional dependencies for zfs-utils
    python: for arcstat/arc_summary/dbufstat [installed]
(2/2) installing zfs-dkms                                                                                                                                                                     [-----------------------------------------------------------------------------------------------------------------------] 100%
:: Running post-transaction hooks...
(1/8) Reloading system manager configuration...
(2/8) Creating temporary files...
/usr/lib/tmpfiles.d/nut.conf:1: Duplicate line for path "/run/nut", ignoring.
/usr/lib/tmpfiles.d/nut.conf:2: Duplicate line for path "/var/lib/nut", ignoring.
(3/8) Reloading device manager configuration...
(4/8) Arming ConditionNeedsUpdate...
(5/8) Install DKMS modules
==> dkms install --no-depmod zfs/2.2.6 -k 6.6.59-1-lts
==> dkms install --no-depmod zfs/2.2.6 -k 6.11.6-arch1-1
configure: error: 
        *** Cannot build against kernel version 6.11.6-arch1-1.
        *** The maximum supported kernel version is 6.10.


Error! Bad return status for module build on kernel: 6.11.6-arch1-1 (x86_64)
Consult /var/lib/dkms/zfs/2.2.6/build/make.log for more information.
==> WARNING: `dkms install --no-depmod zfs/2.2.6 -k 6.11.6-arch1-1' exited 10
==> depmod 6.6.59-1-lts
(6/8) Updating initramfs...
:: Building initramfs for linux (6.11.6-arch1-1)
dracut[I]: Executing: /usr/bin/dracut --force --hostonly --no-hostonly-cmdline /boot/initramfs-linux.img 6.11.6-arch1-1
dracut[I]: *** Including module: bash ***
dracut[I]: *** Including module: shell-interpreter ***
dracut[I]: *** Including module: systemd ***
dracut[I]: *** Including module: systemd-ask-password ***
dracut[I]: *** Including module: systemd-initrd ***
dracut[I]: *** Including module: systemd-journald ***
dracut[I]: *** Including module: systemd-modules-load ***
dracut[I]: *** Including module: systemd-sysctl ***
dracut[I]: *** Including module: systemd-sysusers ***
dracut[I]: *** Including module: systemd-tmpfiles ***
dracut[I]: *** Including module: systemd-udevd ***
dracut[I]: *** Including module: i18n ***
dracut[I]: *** Including module: btrfs ***
dracut[I]: *** Including module: kernel-modules ***
dracut[I]: *** Including module: kernel-modules-extra ***
dracut[I]: *** Including module: zfs ***
dracut-install: Failed to find module 'zfs'
dracut[E]: FAILED:  /usr/lib/dracut/dracut-install -D /var/tmp/dracut.FTvV9R/initramfs -H --kerneldir /lib/modules/6.11.6-arch1-1/ -m zfs
dracut[F]: installkernel failed in module zfs
error: command failed to execute correctly
(7/8) Refreshing PackageKit...
(8/8) Performing snapper post snapshots for the following configurations...
==> root: 6978

What is the issue here?

zfs-dkms hasn’t been patched for kernel 6.11 yet. The easiest solution is to use the LTS kernel. In general, when using zfs you are better off using the LTS kernel unless you are using the archzfs repo.

Alternatively, you could use zfs-dkms-git instead.

1 Like

Or alternatively, compile your own kernel with zfs baked in. Or find a provided kernel that does (I have no idea if any do).
I’m using LTS and zfs-dkms myself as Dalto suggested on a headless server. Trying to run current kernel with ZFS is a moderate nightmare. Unless you really need zfs (which I pretty much do/did), I’d recommend pulling the data and reformatting to another FS.

1 Like

The archzfs repo makes it pretty easy if you ever need to do so for any reason.

For the OP’s scenario though, I would just boot into the LTS kernel though since they already have it installed.

1 Like

But the archzfs is providing zfs for newer kernels like 6.11 without official release for that kernel version. This is not what I would do.

1 Like

It is doing the opposite of that. Not allowing the kernel to update until zfs is ready. It is currently on 6.9.7

To be clear, I think running LTS is the best option. But if you are in a situation where you cannot run LTS, then I think archzfs is an option.

EDIT: Now that I post that, it seems bad. It should really be on 6.10.x and zfs 2.2.6. :frowning:

1 Like

Just booting into LTS did the trick - I am with stupid, ty all guys, much love and respect!

1 Like

I havent checked out archzfs for a while. You are right. It seems to be fine now.

For kernel 6.9 they provided zfs 2.2.4 without official support. I created the ticket at that time:

In the meantime, starting with zfs 2.2.5, the zfs developer implemented a patch that prevent compilation with unsupported kernel version.

Now archzfs is basically forced to stick to the officially supported kernel versions

But 2.2.6 has been released at this point with support for 6.10. It seems like that should be there.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.