[MDEV-24962] Galera SST innobackupex-move ignores Environment settings Created: 2021-02-24  Updated: 2021-05-17  Resolved: 2021-05-10

Status: Closed
Project: MariaDB Server
Component/s: Galera SST
Affects Version/s: 10.5.9
Fix Version/s: 10.6.1, 10.2.39, 10.3.30, 10.4.20, 10.5.11

Type: Bug Priority: Blocker
Reporter: Pavel Cibulka Assignee: Julius Goryavsky
Resolution: Fixed Votes: 0
Labels: None
Environment:

Ubuntu 18.04


Attachments: File mariadb@.service    
Issue Links:
Relates
relates to MDEV-23580 galera_3nodes.galera_ipv6_rsync_secti... Closed

 Description   

We use mariadb galera managed by systemd on Ubuntu 18.04. There is datadir set to environment in systemd config:

Environment='MYSQLD_MULTI_INSTANCE=--defaults-file=/etc/mysql/mariadb-%I.cnf \
                                   --pid-file=/var/run/mariadb-%I/mariadb.pid \
                                   --port=%I \
                                   --socket=/var/run/mariadb-%I/mariadb.sock \
                                   --datadir=/var/lib/mariadb-%I \
                                   --tmpdir=/run/mariadb-%I'

I've needed to add one server into cluster but it keep failing. I've check logs and found this line:

necy1 -innobackupex-move: [00] 2021-02-23 17:08:48 Error: Move file ibdata1 to /var/lib/mysql/ibdata1 failed: Destination file exists

This is default datadir, which we don't use. innobackupex-move seems to ignore environment settings. After adding datadir into mariadb config file innobackupex-move and whole process succeded.

wsrep_sst_method is set to mariabackup

I've added systemd config file for mariadb service.



 Comments   
Comment by Sergei Golubchik [ 2021-03-30 ]

it's not about the environment, MYSQLD_MULTI_INSTANCE is only used to set the datadir for the server, the server invokes sst scripts, but wsrep_sst_mariabackup incorrectly invokes mariabackup, so it seems. It does

INNOMOVE="${INNOBACKUPEX_BIN} ${WSREP_SST_OPT_CONF} --move-back $disver $impts --force-non-empty-directories --target-dir=\${DATA}

where $DATA is datadir, and --datadir is not set (so, gets the default value that shows up in the logs)

Comment by Vladislav Vaintroub [ 2021-03-30 ]

Reassigning to Galera, again.
And jplindst, it would also be about the time to move from innobackupex to mariabackup

Comment by Jan Lindström (Inactive) [ 2021-04-21 ]

Buildbot is not yet happy, there is red lines on mariabackup sst test case. Did you try Ramesh QA script ?

Comment by Jan Lindström (Inactive) [ 2021-04-22 ]

ok to push after adding support for other groups in my.cnf for ssl/tls parameters.

Comment by Julius Goryavsky [ 2021-05-09 ]

The problems have been fixed. Further work on improving the scripts and fixing other errors in them has been moved to MDEV-23580.

Comment by Marko Mäkelä [ 2021-05-10 ]

Resolving the merge conflicts from 10.2 to 10.3 is not trivial. Please fix.

Generated at Thu Feb 08 09:34:01 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.