On an Ampere eMAG system I'm trying to boot from ZFS on root on an attached SSD. I used bsdinstall to partition and configure the disk and installed the kernel/userland manually, and created loader.conf and fstab manually. loader.conf had zfs_load="YES" and vfs.root.mountfrom="zfs:zroot/ROOT/default". on boot the kernel reported KLD file zfs.ko is missing depndencies A similar report from twitter: https://twitter.com/manuvadot/status/1106841888903057408
(In reply to Ed Maste from comment #0) Have you tried to force load zfs dependencies by addding to loader.conf opensolaris_load="YES" That is what I do when I run into this error.
(In reply to Rodney W. Grimes from comment #1) I have to add opensolaris_load="YES" here (RPi3B) as well, but I do not need to set vfs.root.mountfrom as Ed does. Bernd Walter's workflow (https://lists.freebsd.org/pipermail/freebsd-arm/2019-February/019455.html) also mentioned to add opensolaris_load="YES" to loader.conf on arm.
(In reply to Rodney W. Grimes from comment #1) > Have you tried to force load zfs dependencies by addding to loader.conf > opensolaris_load="YES" Yes this is a suitable workaround; I opened this PR to track the underlying bug / issue. (In reply to iz-rpi03 from comment #2) > I do not need to set vfs.root.mountfrom as Ed does. It turns out I didn't actually need vfs.root.mountfrom, it works with only opensolaris_load="YES".
(In reply to Ed Maste from comment #3) > It turns out I didn't actually need vfs.root.mountfrom, it works with only pensolaris_load="YES". I thought that was the case. Last time I ran into this IIRC was before the hints file was being generated and I just attributed it to that. It may be that we have a general "dependency" locating problem on some (arm?) platforms? Might be worth testing if foo_load="othermodulewithdependecny" hauls in those dependencies. Thanks for tracking this. Rod
kldload once the system has booted works as expected: root@:~ # kldstat Id Refs Address Size Name 1 8 0xffff000000000000 14c3a30 kernel 2 1 0xffff0001b4400000 41000 uhid.ko 3 1 0xffff0001b4441000 41000 ums.ko root@:~ # kldload zfs ZFS filesystem version: 5 ZFS storage pool version: features support (5000) root@:~ # kldstat Id Refs Address Size Name 1 18 0xffff000000000000 14c3a30 kernel 2 1 0xffff0001b4400000 41000 uhid.ko 3 1 0xffff0001b4441000 41000 ums.ko 5 1 0xffff0001b4e00000 2c1000 zfs.ko 6 1 0xffff0001b50c1000 47000 opensolaris.ko root@:~ #
A commit references this bug: Author: gjb Date: Wed Oct 2 13:30:17 UTC 2019 New revision: 353004 URL: https://svnweb.freebsd.org/changeset/base/353004 Log: Explicitly add opensolaris_load="YES" to loader.conf through the installer when installing the system on a ZFS root filesystem. For arm64, zfs_load="YES" does not add opensolaris.ko as a kld dependency, so add it explicitly to prevent boot-time failures out-of-box. PR: 240478 MFC after: 3 days Sponsored by: Rubicon Communications, LLC (Netgate) Changes: head/usr.sbin/bsdinstall/scripts/config
A commit references this bug: Author: gjb Date: Thu Oct 3 14:39:16 UTC 2019 New revision: 353047 URL: https://svnweb.freebsd.org/changeset/base/353047 Log: MFC r353004, r353012: r353004: Explicitly add opensolaris_load="YES" to loader.conf through the installer when installing the system on a ZFS root filesystem. For arm64, zfs_load="YES" does not add opensolaris.ko as a kld dependency, so add it explicitly to prevent boot-time failures out-of-box. r353012: Add a comment explaining why the opensolaris_load line in loader.conf is explicitly added. PR: 240478 Approved by: re (kib, early MFC) Sponsored by: Rubicon Communications, LLC (Netgate) Changes: _U stable/11/ stable/11/usr.sbin/bsdinstall/scripts/config _U stable/12/ stable/12/usr.sbin/bsdinstall/scripts/config
A commit references this bug: Author: gjb Date: Thu Oct 3 14:41:21 UTC 2019 New revision: 353048 URL: https://svnweb.freebsd.org/changeset/base/353048 Log: MFS12 r353047: MFC r353004, r353012: r353004: Explicitly add opensolaris_load="YES" to loader.conf through the installer when installing the system on a ZFS root filesystem. For arm64, zfs_load="YES" does not add opensolaris.ko as a kld dependency, so add it explicitly to prevent boot-time failures out-of-box. r353012: Add a comment explaining why the opensolaris_load line in loader.conf is explicitly added. PR: 240478 Approved by: re (kib) Sponsored by: Rubicon Communications, LLC (Netgate) Changes: _U releng/12.1/ releng/12.1/usr.sbin/bsdinstall/scripts/config
After the switch to OpenZFS this line must be added to loader.conf: cryptodev_load="YES"