Do not enable zfs-share.service

zfs-share.service executes `zfs share` on every boot to share any
filesystem/s, that are shared over SMB and/or NFS using the
sharesmb and sharenfs properties.

Since we do not rely on these properties to share over SMB and NFS
and the service fails on boot on TrueNAS if sharesmb and/or
sharenfs properties are set, and we rely on middleware to control
the SMB and NFS shares, zfs-share.service should be disabled for
TrueNAS SCALE.

Signed-off-by: Umer Saleem <usaleem@ixsystems.com>
This commit is contained in:
Umer Saleem 2023-08-24 20:11:59 +05:00 committed by Ameer Hamza
parent 50f9fd6fce
commit 46e619a2ed
3 changed files with 2 additions and 3 deletions

View File

@ -163,7 +163,6 @@ override_dh_installinit:
dh_installinit -r --no-restart-after-upgrade --name zfs-import
dh_installinit -r --no-restart-after-upgrade --name zfs-mount
dh_installinit -r --no-restart-after-upgrade --name zfs-load-key
dh_installinit -R --name zfs-share
dh_installinit -R --name zfs-zed
override_dh_installsystemd:

View File

@ -3,7 +3,7 @@ enable zfs-import-cache.service
disable zfs-import-scan.service
enable zfs-import.target
enable zfs-mount.service
enable zfs-share.service
disable zfs-share.service
enable zfs-zed.service
enable zfs-volume-wait.service
enable zfs.target

View File

@ -17,4 +17,4 @@ EnvironmentFile=-@initconfdir@/zfs
ExecStart=@sbindir@/zfs share -a
[Install]
WantedBy=zfs.target
WantedBy=multi-user.target