From 29819a0177f83c0f2ae530dc71a267218e134b78 Mon Sep 17 00:00:00 2001 From: Turbo Fredriksson Date: Thu, 4 Dec 2025 14:09:20 +0000 Subject: [PATCH] Add missing initrd config variables. The `ZFS_INITRD_ADDITIONAL_DATASETS` variable is used in the initrd script to boot additional OS file systems besides the root file system. But it wasn't included as an example in the config files. The `ZFS_POOL_EXCEPTIONS` *was* included in the example defaults file, but it was not exported, so not available in the initrd. Reviewed by: Brian Behlendorf Reviewed-by: Rob Norris Signed-off-by: Turbo Fredriksson Closes #18000 --- etc/default/zfs.in | 4 ++++ etc/zfs/zfs-functions.in | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/etc/default/zfs.in b/etc/default/zfs.in index ae813e9de..5202cf502 100644 --- a/etc/default/zfs.in +++ b/etc/default/zfs.in @@ -60,6 +60,10 @@ ZPOOL_IMPORT_ALL_VISIBLE='no' # This is a space separated list. #ZFS_POOL_EXCEPTIONS="test2" +# Additional important (operating system) file systems to mount beside +# the root file system. +#ZFS_INITRD_ADDITIONAL_DATASETS="rpool/usr rpool/var rpool/var/spool" + # Should the datasets be mounted verbosely? # A mount counter will be used when mounting if set to 'yes'. VERBOSE_MOUNT='no' diff --git a/etc/zfs/zfs-functions.in b/etc/zfs/zfs-functions.in index 9ae8b40d4..5d646e9ea 100644 --- a/etc/zfs/zfs-functions.in +++ b/etc/zfs/zfs-functions.in @@ -109,7 +109,7 @@ fi # ---------------------------------------------------- export ZFS ZED ZPOOL ZPOOL_CACHE ZFS_LOAD_KEY ZFS_UNLOAD_KEY ZFS_MOUNT ZFS_UNMOUNT \ - ZFS_SHARE ZFS_UNSHARE + ZFS_SHARE ZFS_UNSHARE ZFS_POOL_EXCEPTIONS ZFS_INITRD_ADDITIONAL_DATASETS zfs_action() {