Does xtrabackup tool support MySQL innodb cluster 5.7

Hi, team
We have one MySQL innodb cluster enviornment, which includes one master plus two slave servers. In the begining, we use mysqldump to backup databases, and later we also import the dumpped database to new enviornment to setup data. As you know, mysqldump doesn’t support incremental backup, and we find xtrabackup support it.
We’d like to know if xtrabackup support (both full and incremental) backup MySQL innodb cluster (5.7), and somtimes we find master maybe down becasue of IO problem, and then master will be switched to one of the previous slaves. If this ocurred, is the old xtrabackup backup remain valid. Since I see xtrabackup copies the local database data files on one specific MySQL server, later, both configuration files or data files maybe different on the new master node.

Regards,
-Liang

1 Like

Thanks @lcheng for your question.

If the master changes, it means, it is using different instance. so incremental backup cannot work based on the full backup from old instance/machine.
Innodb incremental works at physical layer. LSNs are not same across GR clusters. All the GR,PXC replication is kind of logical (ie based on binlog row images)

1 Like

Thanks for your reply.

If not consider master switch case for now, I’d like to confirm other things.

  1. I tried the full backup, and once it’s completed, I don’t find any binlog in the target folder. Does it mean the binlog is not handled by xtrabackup.

  2. If one slave is down, and we want to recover it. Is the restore steps within The Backup Cycle - Full Backups can be used to recover the innodb cluster slave node. I bring up this question, because we sometimes meet binlog issue when we try to recover slave nodes, it always failed at binlog sync step

  3. Another question is we have one new requirment, that is we will have two environments running at the same time, both are innodb clusters. Do you think is it possible that we can sync/replicate the data betwwen enviornments. Say env1(3 nodes) is the main envirnonment, one day, we will setup env2 (3 nodes) based on full backup on env1, and start env2. Later, New data is generated and some data is also updated on env1, then we make a increment backup on env1. After that, we want to apply the change to env2, how do we do? Based on my current understand, we still need to merge the incremental update to the backup target folder on env1 first, then we copy the whole backup folder to env2, stop the whole env2, run following commands on each node one by one: clean up all mysql data folder, and run copy-back command to restore the full backup on env2, and restart env2, please let me know if it’s the case.
    Or can we copy the increment backup to env2, since we alreay have the first full backup on env2 (copied from env1), merge the incremental backup into its full backup folder. Later, we do the same remaining things, that is, stop whole v2, remove all files from env2, run copy-back command, restart env2.

  4. If some MySQL variables are different betwwen env1 and env2, e.g. cache setting, group_replication setting, etc, will it impact the process of backup/restore

Regards,
-Liang

1 Like