Solved nanobsd 13.0 and zfs

Hello,
I have a nanobsd machine running from an sdcard. Plus, it has a disk formatted as zfs to store files.
From a few versions until now, a link from /boot/zfs to /etc/ ( nanobsd is read-only, only /etc can be written to disk) was enough to store/save zpool.cache and allow zfs to start on boot.
But with 13.0, this does not work anymore.

I can manually import the zpool and save /etc/zfs/zpool.cache by running sh save_cfg. But on next boot, the file seems to be ignored and the pool is not imported.

Do you know how to solve this and allow the zpool to be imported automatically ?
 
For anyone facing the same issue, the solution was to move zfs_enable="YES" from /etc/rc.conf.d/zfs to /etc/rc.conf as found here
 
I think in rc.conf
Code:
zpool_enable="YES"
Hello,

The "problem" is that some zfs services (zfs zpool and zvol) need the "zfs_enable" rcvar to be true and are looking for this value either in /etc/rc.conf or in /etc/rc.conf.d/SERVICE_NAME.
That is why using /etc/rc.conf.d/zfs only is not enough.
So:
  • The simplest solution is to configure zfs_enable="YES" in /etc/rc.conf.
  • The less simple solution is to configure it in /etc/rc.conf.d/zfs, /etc/rc.conf.d/zpool and /etc/rc.conf.d/zvol
 
Back
Top