mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-11-17 10:01:01 +03:00
ae12b02308
This is a minor change to the systemd service templates that verifies the zfs kernel module is loaded by the kernel prior to attempting to import any zpool. Reviewed-by: Richard Laager <rlaager@wiktel.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Jonathon Fernyhough <jonathon.fernyhough@york.ac.uk> Closes #10627
21 lines
530 B
SYSTEMD
21 lines
530 B
SYSTEMD
[Unit]
|
|
Description=Import ZFS pools by cache file
|
|
Documentation=man:zpool(8)
|
|
DefaultDependencies=no
|
|
Requires=systemd-udev-settle.service
|
|
After=systemd-udev-settle.service
|
|
After=cryptsetup.target
|
|
After=multipathd.target
|
|
After=systemd-remount-fs.service
|
|
Before=zfs-import.target
|
|
ConditionPathExists=@sysconfdir@/zfs/zpool.cache
|
|
|
|
[Service]
|
|
Type=oneshot
|
|
RemainAfterExit=yes
|
|
ExecCondition=/usr/bin/grep -q "^zfs " /proc/modules
|
|
ExecStart=@sbindir@/zpool import -c @sysconfdir@/zfs/zpool.cache -aN
|
|
|
|
[Install]
|
|
WantedBy=zfs-import.target
|