diff options
Diffstat (limited to 'scripts/wsrep_sst_rsync.sh')
| -rw-r--r-- | scripts/wsrep_sst_rsync.sh | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/scripts/wsrep_sst_rsync.sh b/scripts/wsrep_sst_rsync.sh index 7096bb4b330..ddf41559c29 100644 --- a/scripts/wsrep_sst_rsync.sh +++ b/scripts/wsrep_sst_rsync.sh @@ -38,6 +38,9 @@ cleanup_joiner() local estatus=$? if [ $estatus -ne 0 ]; then wsrep_log_error "Cleanup after exit with status: $estatus" + elif [ -z "${coords:-}" ]; then + estatus=32 + wsrep_log_error "Failed to get current position" fi local failure=0 @@ -408,7 +411,7 @@ EOF # (b) Cluster state ID & wsrep_gtid_domain_id to be written to the file, OR # (c) ERROR file, in case flush tables operation failed. - while [ ! -r "$FLUSHED" ] && \ + while [ ! -r "$FLUSHED" ] || \ ! grep -q -F ':' -- "$FLUSHED" do # Check whether ERROR file exists. @@ -433,8 +436,8 @@ EOF # Let's check the existence of the file with the index: if [ -f "$WSREP_SST_OPT_BINLOG_INDEX" ]; then # Let's read the binlog index: - max_binlogs=$(parse_cnf "$encgroups" 'sst-max-binlogs') - if [ -n "$max_binlogs" ]; then + max_binlogs=$(parse_cnf "$encgroups" 'sst-max-binlogs' 1) + if [ $max_binlogs -ge 0 ]; then binlog_files="" if [ $max_binlogs -gt 0 ]; then binlog_files=$(tail -n $max_binlogs \ |
