Issue loading OpenZFS kernel modules in Fedora Silverblue
Hello good people,
Hoping this is an appropriate place for troubleshooting questions, I'm learning Linux & OpenZFS in preparation of a server + NAS build, currently working in VMware Workstation.
I have successfully setup OpenZFS on Fedora 39 and have configured my zpool using virtual disks.
Now I am looking to replicate the setup on Fedora Silverblue: setup OpenZFS, import the existing disks, then attach the zpool.
8. zfs, zpool seem ok as I can get the help output or read the man pages, however:
zpool status The ZFS modules cannot be auto-loaded. Try running 'modprobe zfs' as root to manually load them.
zfs get all The ZFS modules cannot be auto-loaded. Try running 'modprobe zfs' as root to manually load them.
Obviously, I'm missing something due to my gaps in experience with Linux.
I see that Universal Blue has incorporated OpenZFS as described on the GitHub page, so it should be possible for me to achieve this as well, I suppose.
Any pointers, documentation or advice is appreciated!
Even if you can get it to work, running ZFS on fedora generally is an exercise in frustration because the kernels update to newer versions than what ZFS supports anyway.
Thank you! This is the page where I discovered that I can try rpm-ostree kargs --append=modprobe=zfs, which didn't work.
Still, as far as I understand it, ublue managed to overcome this, as they do offer a Fedora version with zfs included.
What am I missing?
I don't use Fedora, but I have ZFS on all my Arch systems for everything (including root fs). So, I'll make a guess - is the package you installed for ZFS a DKMS kernel module, or a binary one? That's the first thing. If it's a DKMS module, I don't see anything on your output showing it was compiled, which would explain the module not loading. If it's a binary module in that package, it must be for the exact same version of the kernel that is installed - exact same. If it mismatches then you need either a different kennel or different ZFS package. In either case, you'll probably need to wire in a hook for your initramfs, but it looks that part might be ok from your output. Hope that helps, good luck. ZFS is incredibly good.
Unfortunately this is why I chose to run Ubuntu server. As far as I know, it's the only distro with ZFS set up by default. I wish you luck, as I run Silverblue as my desktop and would love to run it for my server too!
I would recommend AlmaLinux in that case. It takes the place of CentOS, which was the free edition of Red Hat. Fedora is targeted at the desktop, not servers.
You could do it, but I haven't heard about people using Silverblue as a server yet.
You wouldn’t use Silverblue on a server, you’d use Fedora CoreOS (FCOS) or CentOS Stream CoreOS (COSS). The ublue project has a FCOS derivative called ucore with options for ZFS OOTB. I use it on my server.
There’s some examples on how you’d use dockerfiles to build a ZFS module (as well as other things) from Fedora as well.
In any case, building bootable container images containing stuff like kernel modules is currently how this type of thing is done on atomic Fedora variants.