# How to copy data from a Master PXC to a Slave PXC

**URL:** https://forums.percona.com/t/how-to-copy-data-from-a-master-pxc-to-a-slave-pxc/7589
**Category:** Percona Server for MySQL 5.6
**Created:** [April 29, 2020, 10:24am UTC](https://forums.percona.com/t/how-to-copy-data-from-a-master-pxc-to-a-slave-pxc/7589 "2020-04-29T10:24:12Z")
**Posts on this page:** 1
**Showing post:** 5

<div class="post-metadata">

### Author: ![soprano](https://avatars.discourse-cdn.com/v4/letter/s/b3f665/32.png) [@soprano](https://forums.percona.com/u/soprano)
#### Post date: [May 4, 2020, 3:51am UTC](https://forums.percona.com/t/how-to-copy-data-from-a-master-pxc-to-a-slave-pxc/7589/5 "2020-05-04T03:51:59Z")

</div>

hmmm i have still some problems  
on the slave i removed all the datadir files  
on the 3rd node of 1 PXC i ran  
xtrabackup --backup --target-dir=/backup/backup\_20200504  
xtrabackup --prepare --target-dir=/backup/backup\_20200504  
then rsync on the slave /backup directory  
then on the slave i did  
cd /backup  
rm -rf /var/lib/mysql (this is the datadir of Percona mysql)  
xtrabackup --move-back --target-dir=/var/lib/mysql  
and i get&nbsp;  
xtrabackup version 2.3.10 based on MySQL server 5.6.24 Linux (x86\_64) (revision id: bd0d4403f36)200504 11:21:31 [01] Moving ibdata1 to /var/lib/mysql/ibdata1Can not move file ibdata1 to /var/lib/mysql/ibdata1: No such file or directory  
what i have to do ?  
Thanks in advance  
Claudio

---

_[View the full topic](https://forums.percona.com/t/how-to-copy-data-from-a-master-pxc-to-a-slave-pxc/7589)._
