LP #1326012: SST fails when binlogs are in dedicated directory that's located inside datadir

Description

**Reported in Launchpad by Przemek last update 17-11-2015 11:40:56

This seems to be a regression introduced by bug fix to lp:1273368

When log_bin is set to a directory that is located inside the datadir, with wsrep_sst_method=xtrabackup-v2 the SST fails as the directory is removed first as any other database dir, and then the script tries to remove the dir for binary logs again.
Both PXC 5.6.15+ and 5.5.37+ are affected.

How to reproduce:

my.cnf:
datadir=/var/lib/mysql
wsrep_sst_method=xtrabackup-v2
log-bin=/var/lib/mysql/log/my-bin

force an SST results in this error log:

(...)
removed directory: `/var/lib/mysql/log'
(...)
removed `/var/lib/mysql/ib_logfile0'
WSREP_SST: [INFO] Cleaning the binlog directory /var/lib/mysql/log as well (20140603 15:04:08.295)
find: `/var/lib/mysql/log': No such file or directory
WSREP_SST: [ERROR] Cleanup after exit with status:1 (20140603 15:04:08.304)
WSREP_SST: [INFO] Removing the sst_in_progress file (20140603 15:04:08.306)
2014-06-03 15:04:08 30482 [ERROR] WSREP: Process completed with error: wsrep_sst_xtrabackup-v2 --role 'joiner' --address '10.0.1.6' --auth 'root' --datadir '/var/lib/mysql/' --defaults-file '/etc/my.cnf' --parent '30482' '' : 1 (Operation not permitted)
2014-06-03 15:04:08 30482 [ERROR] WSREP: Failed to read uuid:seqno from joiner script.
2014-06-03 15:04:08 30482 [ERROR] WSREP: SST failed: 1 (Operation not permitted)
2014-06-03 15:04:08 30482 [ERROR] Aborting

Environment

None

Smart Checklist

Activity

Show:
Done

Details

Assignee

Reporter

Priority

Smart Checklist

Created January 12, 2018 at 11:29 AM
Updated December 20, 2023 at 5:56 AM
Resolved December 30, 2022 at 10:42 AM