Content-type: text/html
Manpage of ZFS\-MOUNT\-GENERATOR
ZFS\-MOUNT\-GENERATOR
Section: (8)
Updated: ZFS
Index
Return to Main Contents
NAME
zfs-mount-generator - generates systemd mount units for ZFS
SYNOPSIS
/lib/systemd/system-generators/zfs-mount-generator
DESCRIPTION
zfs-mount-generator implements the Generators Specification
of
systemd(1),
and is called during early boot to generate
systemd.mount(5)
units for automatically mounted datasets. Mount ordering and dependencies
are created for all tracked pools (see below). If a dataset has
canmount=on
and
mountpoint
set, the
auto
mount option will be set, and a dependency for
local-fs.target
on the mount will be created.
Because zfs pools may not be available very early in the boot process,
information on ZFS mountpoints must be stored separately. The output
of the command
-
zfs list -H -o name,mountpoint,canmount,atime,relatime,devices,exec,readonly,setuid,nbmand,encroot,keylocation
for datasets that should be mounted by systemd, should be kept
separate from the pool, at
-
/usr/local/etc/zfs/zfs-list.cache/POOLNAME
The cache file, if writeable, will be kept synchronized with the pool
state by the ZEDLET
-
history_event-zfs-list-cacher.sh .
EXAMPLE
To begin, enable tracking for the pool:
-
touch
/usr/local/etc/zfs/zfs-list.cache/POOLNAME
Then, enable the tracking ZEDLET:
-
ln -s "/usr/local/libexec/zfs/zed.d/history_event-zfs-list-cacher.sh" "/usr/local/etc/zfs/zed.d"
systemctl enable zed.service
systemctl restart zed.service
Force the running of the ZEDLET by setting canmount=on for at least one dataset in the pool:
-
zfs set canmount=on
DATASET
This forces an update to the stale cache file.
SEE ALSO
zfs(5)
zfs-events(5)
zed(8)
zpool(5)
systemd(1)
systemd.target(5)
systemd.special(7)
systemd.mount(7)
Index
- NAME
-
- SYNOPSIS
-
- DESCRIPTION
-
- EXAMPLE
-
- SEE ALSO
-
This document was created by
man2html,
using the manual pages.
Time: 00:49:32 GMT, September 27, 2019