SST does not clobber backup-my.cnf

Bug #1431101 reported by Jervin R
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Percona XtraDB Cluster moved to https://jira.percona.com/projects/PXC
Status tracked in 5.6
5.5
Fix Released
Medium
Alexey Kopytov
5.6
Fix Released
Medium
Alexey Kopytov

Bug Description

Xtrabackup-v2 SST fails because backup-my.cnf exists:

2015-03-12 01:06:37 17347 [Note] WSREP: Requesting state transfer: success, donor: 1
WSREP_SST: [INFO] WARNING: Stale temporary SST directory: /var/lib/mysql//.sst from previous state transfer (20150312 01:06:37.785)
WSREP_SST: [INFO] Proceeding with SST (20150312 01:06:37.793)
WSREP_SST: [INFO] Evaluating socat -u TCP-LISTEN:4444,reuseaddr stdio | xbstream -x; RC=( ${PIPESTATUS[@]} ) (20150312 01:06:37.794)
WSREP_SST: [INFO] Cleaning the existing datadir and innodb-data/log directories (20150312 01:06:37.796)
removed `/var/lib/mysql/mysqld.sock'
removed `/var/lib/mysql/mysql-bin.index'
removed `/var/lib/mysql/mysql-bin.000001'
removed `/var/lib/mysql/ibdata1'
removed `/var/lib/mysql/ib_logfile0'
removed `/var/lib/mysql/ib_logfile1'
removed `/var/lib/mysql/auto.cnf'
WSREP_SST: [INFO] Waiting for SST streaming to complete! (20150312 01:06:37.834)
2015-03-12 01:06:39 17347 [Note] WSREP: (07d9cf83, 'tcp://0.0.0.0:4567') turning message relay requesting off
xbstream: Can't create/write to file '././backup-my.cnf' (Errcode: 17 - File exists)
xbstream: failed to create file.
2015/03/12 01:06:48 socat[17603] E write(1, 0x1060400, 8192): Broken pipe
WSREP_SST: [ERROR] Error while getting data from donor node: exit codes: 1 1 (20150312 01:06:48.105)
WSREP_SST: [ERROR] Cleanup after exit with status:32 (20150312 01:06:48.108)
2015-03-12 01:06:48 17347 [ERROR] WSREP: Process completed with error: wsrep_sst_xtrabackup-v2 --role 'joiner' --address '192.168.90.3' --auth '' --datadir '/var/lib/mysql/' --defaults-file '/etc/my.cnf' --parent '17347' '' : 32 (Broken pipe)
2015-03-12 01:06:48 17347 [ERROR] WSREP: Failed to read uuid:seqno from joiner script.
2015-03-12 01:06:48 17347 [ERROR] WSREP: SST failed: 32 (Broken pipe)
2015-03-12 01:06:48 17347 [ERROR] Aborting

mysql> show global variables like '%version%';
+-------------------------+---------------------------------------------------------------------------------------------------+
| Variable_name | Value |
+-------------------------+---------------------------------------------------------------------------------------------------+
| innodb_version | 5.6.22-72.0 |
| protocol_version | 10 |
| slave_type_conversions | |
| version | 5.6.22-72.0-56-log |
| version_comment | Percona XtraDB Cluster (GPL), Release rel72.0, Revision 978, WSREP version 25.8, wsrep_25.8.r4150 |
| version_compile_machine | x86_64 |
| version_compile_os | Linux |
+-------------------------+---------------------------------------------------------------------------------------------------+
7 rows in set (0.00 sec)

mysql> show global status like '%version%';
+------------------------+---------------+
| Variable_name | Value |
+------------------------+---------------+
| Ssl_version | |
| wsrep_protocol_version | 7 |
| wsrep_provider_version | 3.9(r93aca2d) |
+------------------------+---------------+
3 rows in set (0.00 sec)

Tags: i53079 i54738
Revision history for this message
Jervin R (revin) wrote :

The backup-my.cnf is on /var/lib/mysql/.sst/backup.my.cnf on the joiner.

Revision history for this message
Raghavendra D Prabhu (raghavendra-prabhu) wrote :

@Jervin,

Yes, with a $DATADIR/.sst/backup.my.cnf, this can occur.

The .sst directory can only exist if a previous SST failed, and it is not removed as follows:

        wsrep_log_info "Moving the backup to ${TDATA}"
        timeit "Xtrabackup move stage" "$INNOMOVE"
        if [[ $? -eq 0 ]];then
            wsrep_log_info "Move successful, removing ${DATA}"
            rm -rf $DATA
            DATA=${TDATA}
        else
            wsrep_log_error "Move failed, keeping ${DATA} for further diagnosis"
            wsrep_log_error "Check ${DATA}/innobackup.move.log for details"
        fi

tags: added: i53079
tags: added: i54738
Revision history for this message
Alexey Kopytov (akopytov) wrote :
Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PXC-1120

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.