diff options
author | David Teigland <teigland@redhat.com> | 2018-09-13 10:50:50 -0500 |
---|---|---|
committer | David Teigland <teigland@redhat.com> | 2018-09-13 10:50:50 -0500 |
commit | e9b6cdd6e65196d6ada6ce54e8d256c3dc57329b (patch) | |
tree | 873cfe9458f99856616bd04c4b46ba88153e1467 | |
parent | 81ca0cb1619b6ea22fa68f54783cd62dafbd2eaf (diff) | |
download | lvm2-e9b6cdd6e65196d6ada6ce54e8d256c3dc57329b.tar.gz |
add lvmlocks service to start and stop lockspaces
-rw-r--r-- | scripts/lvmlocks.service.in | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/scripts/lvmlocks.service.in b/scripts/lvmlocks.service.in new file mode 100644 index 000000000..79598db8f --- /dev/null +++ b/scripts/lvmlocks.service.in @@ -0,0 +1,18 @@ +[Unit] +Description=LVM locking start and stop +Documentation=man:lvmlockd(8) +After=lvm2-lvmlockd.service sanlock.service dlm.service + +[Service] +Type=oneshot +RemainAfterExit=yes + +# start lockspaces and wait for them to finish starting +ExecStart=@SBINDIR@/lvm vgchange --lock-start --lock-opt autowait + +# stop lockspaces and wait for them to finish stopping +ExecStop=@SBINDIR@/lvmlockctl --stop-lockspaces --wait 1 + +[Install] +WantedBy=multi-user.target + |