Hi guix-developers, I'm trying to get ZFS working on a test VM running Guix System.
Attempting to do a simple `guix install zfs` does not work, as I reported in https://issues.guix.gnu.org/45401 , ZFS 0.8.5 is only up to kernel 5.9 but latest guix has kernel 5.10. I created a procedure to modify the base `zfs` package and compile it for a different Linux kernel: ```scheme (define (make-zfs-package kernel) (package (inherit zfs) (name (string-append "zfs-for-" (package-name kernel) "-" (package-version kernel) "-version")) (arguments (cons* #:linux kernel (package-arguments zfs))))) ``` Then in my system configuration `.scm`, I selected a specific Linux and had its module added to the boot and had it loaded in a Shepherd service: ```scheme (define system-kernel linux-libre-5.4) (define system-zfs (make-zfs-package system-kernel)) ;; ... (operating-system (kernel system-kernel) (kernel-loadable-modules (list (list system-zfs "module"))) ;; ... (packages (cons* system-zfs ; ... %base-packages)) ;; ... (services (cons* (service kernel-module-loader-service-type '("zfs")) ; ... %base-services)) ;; ... ) ``` As I documented here: https://issues.guix.gnu.org/45592#1 Now ZFS is loaded at boot (`lsmod | grep zfs` shows ZFS loaded), and `zfs version` and `zpool list` don't error out. However, when I created some extra space in the QEMU image and created a partition `vda3`, I get an error in `zpool create tank vda3`. The error is `cannot mount 'tank': Input/output error`. I've also tried adding a new device to the QEMU boot as well, also the same occurs. Looking at a partition editor, the partition does get formatted as zfs, it just won't mount. Has anyone ever managed to get ZFS working on Guix? Any tips? Is it enough to `modprobe` it in a system service or does it have to somehow be added to the Linux command line? Maybe it only works on even older Linux-libre versions than 5.4? Thanks raid5atemyhomework