mirror of
https://git.proxmox.com/git/mirror_corosync
synced 2025-10-04 00:31:15 +00:00
init: Use corosync-cfgtool for shutdown
... to trigger cfg shutdown callbacks. Signed-off-by: Jan Friesse <jfriesse@redhat.com> Reviewed-by: Christine Caulfield <ccaulfie@redhat.com>
This commit is contained in:
parent
119d0b87ad
commit
191bec5d1d
@ -176,6 +176,9 @@ stop()
|
||||
! status -p "$prog_pid_file" "$prog" > /dev/null 2>&1 && return
|
||||
|
||||
echo -n "Signaling $desc ($prog) to terminate: "
|
||||
# Call cfgtool to trigger shutdown callbacks
|
||||
corosync-cfgtool -H --force > /dev/null 2>&1
|
||||
# Send TERM signal (if cfgtool -H failed)
|
||||
kill -TERM "$(pid_var_run $prog_pid_file)" > /dev/null 2>&1
|
||||
success
|
||||
echo
|
||||
|
@ -8,6 +8,7 @@ After=network-online.target
|
||||
[Service]
|
||||
EnvironmentFile=-@INITCONFIGDIR@/corosync
|
||||
ExecStart=@SBINDIR@/corosync -f $COROSYNC_OPTIONS
|
||||
ExecStop=@SBINDIR@/corosync-cfgtool -H --force
|
||||
Type=notify
|
||||
|
||||
# In typical systemd deployments, both standard outputs are forwarded to
|
||||
|
Loading…
Reference in New Issue
Block a user