Skip to content

Commit

Permalink
MDEV-22554: galera_sst_mariabackup fails with "Failed to start mysqld.2"
Browse files Browse the repository at this point in the history
The problem is caused by the operation of netcat streamer and does
not appear on systems where socat is installed. We need to add the
"-N" option for netcat to call shutdown() on the socket when receiving
EOF from STDIN.
  • Loading branch information
sysprg committed May 18, 2020
1 parent d0e3b0e commit f9d8571
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion scripts/wsrep_sst_mariabackup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,11 @@ get_transfer()
tcmd="nc ${REMOTEIP} ${TSST_PORT}"
elif nc -h 2>&1 | grep -q -- '-d\>';then
# Debian netcat
tcmd="nc ${REMOTEIP} ${TSST_PORT}"
if nc -h 2>&1 | grep -q -- '-N\>';then
tcmd="nc -N ${REMOTEIP} ${TSST_PORT}"
else
tcmd="nc ${REMOTEIP} ${TSST_PORT}"
fi
else
# traditional netcat
tcmd="nc -q0 ${REMOTEIP} ${TSST_PORT}"
Expand Down

0 comments on commit f9d8571

Please sign in to comment.