summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZdenek Kabelac <zkabelac@redhat.com>2018-06-12 16:27:42 +0200
committerZdenek Kabelac <zkabelac@redhat.com>2018-06-14 22:02:01 +0200
commitb58160a1913fdd61c378479f6362bd904e7de942 (patch)
tree14d91232063d7a520975bb4e0e1fdb04f7034080
parenta35098b1102eb7f387e90bd16da4cf3ed833ca57 (diff)
downloadlvm2-b58160a1913fdd61c378479f6362bd904e7de942.tar.gz
systemd: add conficting sockets
Since we are using "DefaultDependencies=no" we do not get automatic STOP job on socket connection - so automatically refuse connection on shutdown by adding this Conflict definition to socket Unit.
-rw-r--r--scripts/lvm2_lvmetad_systemd_red_hat.socket.in1
-rw-r--r--scripts/lvm2_lvmpolld_systemd_red_hat.socket.in1
2 files changed, 2 insertions, 0 deletions
diff --git a/scripts/lvm2_lvmetad_systemd_red_hat.socket.in b/scripts/lvm2_lvmetad_systemd_red_hat.socket.in
index 9575f98a6..2663c7245 100644
--- a/scripts/lvm2_lvmetad_systemd_red_hat.socket.in
+++ b/scripts/lvm2_lvmetad_systemd_red_hat.socket.in
@@ -2,6 +2,7 @@
Description=LVM2 metadata daemon socket
Documentation=man:lvmetad(8)
DefaultDependencies=no
+Conflicts=shutdown.target
[Socket]
ListenStream=@DEFAULT_RUN_DIR@/lvmetad.socket
diff --git a/scripts/lvm2_lvmpolld_systemd_red_hat.socket.in b/scripts/lvm2_lvmpolld_systemd_red_hat.socket.in
index ca9f1237f..0537d7f3a 100644
--- a/scripts/lvm2_lvmpolld_systemd_red_hat.socket.in
+++ b/scripts/lvm2_lvmpolld_systemd_red_hat.socket.in
@@ -2,6 +2,7 @@
Description=LVM2 poll daemon socket
Documentation=man:lvmpolld(8)
DefaultDependencies=no
+Conflicts=shutdown.target
[Socket]
ListenStream=@DEFAULT_RUN_DIR@/lvmpolld.socket