diff options
author | Brian Behlendorf <[email protected]> | 2020-11-28 11:11:18 -0800 |
---|---|---|
committer | GitHub <[email protected]> | 2020-11-28 11:11:18 -0800 |
commit | b2a54a28b5ebad7165bbf10bd4de8066a6bf335d (patch) | |
tree | 537dcd27423294dc8318b36ee6745e1833778d49 /etc | |
parent | 16692e6ba0bc3b0b6e7d64a68e91ded9f2d0959e (diff) |
Verify zfs module loaded before starting services
Extend the change made in ae12b02 to verify the zfs kernel
modules are loaded to the rest of the OpenZFS services. If
the modules aren't loaded the neither the share, volume, or
and zed services can be started.
Signed-off-by: Brian Behlendorf <[email protected]>
Closes #11243
Diffstat (limited to 'etc')
-rw-r--r-- | etc/systemd/system/zfs-share.service.in | 1 | ||||
-rw-r--r-- | etc/systemd/system/zfs-volume-wait.service.in | 1 | ||||
-rw-r--r-- | etc/systemd/system/zfs-zed.service.in | 1 |
3 files changed, 3 insertions, 0 deletions
diff --git a/etc/systemd/system/zfs-share.service.in b/etc/systemd/system/zfs-share.service.in index b72008587..745077513 100644 --- a/etc/systemd/system/zfs-share.service.in +++ b/etc/systemd/system/zfs-share.service.in @@ -8,6 +8,7 @@ Wants=zfs-mount.service After=zfs-mount.service PartOf=nfs-server.service nfs-kernel-server.service PartOf=smb.service +ConditionPathIsDirectory=/sys/module/zfs [Service] Type=oneshot diff --git a/etc/systemd/system/zfs-volume-wait.service.in b/etc/systemd/system/zfs-volume-wait.service.in index 75bd9fcdd..4c77724d8 100644 --- a/etc/systemd/system/zfs-volume-wait.service.in +++ b/etc/systemd/system/zfs-volume-wait.service.in @@ -3,6 +3,7 @@ Description=Wait for ZFS Volume (zvol) links in /dev DefaultDependencies=no After=systemd-udev-settle.service After=zfs-import.target +ConditionPathIsDirectory=/sys/module/zfs [Service] Type=oneshot diff --git a/etc/systemd/system/zfs-zed.service.in b/etc/systemd/system/zfs-zed.service.in index f4313625e..008075138 100644 --- a/etc/systemd/system/zfs-zed.service.in +++ b/etc/systemd/system/zfs-zed.service.in @@ -1,6 +1,7 @@ [Unit] Description=ZFS Event Daemon (zed) Documentation=man:zed(8) +ConditionPathIsDirectory=/sys/module/zfs [Service] ExecStart=@sbindir@/zed -F |