Commit 216d5f78 authored by Tao ZHOU's avatar Tao ZHOU Committed by GitHub

use `ps -p` instead of `ps --pid`

make it compatible on FreeBSD.
If the parent process does not exist, there's no need to kill it.
parent 0e794c6a
......@@ -651,13 +651,12 @@ monitor_process()
while true ; do
if ! ps --pid "${WSREP_SST_OPT_PARENT}" &>/dev/null; then
if ! ps -p "${WSREP_SST_OPT_PARENT}" &>/dev/null; then
wsrep_log_error "Parent mysqld process (PID:${WSREP_SST_OPT_PARENT}) terminated unexpectedly."
kill -- -"${WSREP_SST_OPT_PARENT}"
exit 32
fi
if ! ps --pid "${sst_stream_pid}" &>/dev/null; then
if ! ps -p "${sst_stream_pid}" &>/dev/null; then
break
fi
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment