# Problem with master info when creating a slave from an existing slave with Xtrabackup

**URL:** <https://forums.percona.com/t/problem-with-master-info-when-creating-a-slave-from-an-existing-slave-with-xtrabackup/3975>\
**Category:** Percona XtraBackup\
**Created:** [January 1, 2015, 8:53pm UTC](https://forums.percona.com/t/problem-with-master-info-when-creating-a-slave-from-an-existing-slave-with-xtrabackup/3975 "2015-01-01T20:53:14Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![turagittech](https://avatars.discourse-cdn.com/v4/letter/t/ba8739/32.png) [@turagittech](https://forums.percona.com/u/turagittech)\
**Post date:** [January 1, 2015, 8:53pm UTC](https://forums.percona.com/t/problem-with-master-info-when-creating-a-slave-from-an-existing-slave-with-xtrabackup/3975/1 "2015-01-01T20:53:14Z")

</div>

We tried a couple of days ago to create a slave using an existing slave as the place to copy from, we are using mariadb 10.0.14.

We tried a couple of ways to point that slave to the master and in the end had to use the original slave as the master for this slave, creating a daisy chain instead of two slave directly pointing to the one master.  
That slave has log\_bin enabled and the log\_bin file numbers on it are at a higher number than the current master. This occurred due to this slave having been a master previously and us not disabling log\_bin when restarting the slave after switching masters.  
Using the notes at [url][Percona XtraBackup](http://www.percona.com/doc/percona-xtrabackup/2.1/howtos/setting_up_replication.html%5B/url%5D) to create a slave from an existing slave left us a little short and had to work a couple of things out.  
The xtrabackup\_slave\_info file contained change master to slave\_pos for GTID not being fully across GTID I wasn’t sure how the slave was supposed to sync first with a file and position number.  
There are a few steps missing for mariadb in that note now pertaining to how mariadb gtid is implemented  
My question is what are the steps to take this from a copied sslave to getting it to sync to the master not the other slave as its mater creating a daisy chain?  
Should I enable GTID as we are not currently using it?  
Was it just a case of entering “Change master to master\_host Master\_user, Master\_password” without master\_file and position  
followed by Change master to slave\_pos  
and then Slave Start?  
Would that have allowed that slave to join the actual master and rectify the Log\_bin file numbers and position being different?  
master mysql-bin.000018  
slave 1 mysql-bin.000021

Should I now enable gtid so allowing me to switch from slave 1 as the master for slave two or is this problem of position number being higher a real problem?  
I do have the option of turning the bin\_log off on slave 1 forcing a change in behaviour but perhaps other don’t and I may not at some stage in the future.

Any assistance is greatly appreciated

Peter

---

<div class="post-metadata">

**Author:** ![jrivera](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/jrivera/32/13_2.png) [@jrivera](https://forums.percona.com/u/jrivera)\
**Post date:** [January 6, 2015, 7:12am UTC](https://forums.percona.com/t/problem-with-master-info-when-creating-a-slave-from-an-existing-slave-with-xtrabackup/3975/2 "2015-01-06T07:12:46Z")

</div>

I think you are affected by this bug:

- [url][https://bugs.launchpad.net/percona-xtrabackup/+bug/1404484[/url]](https://bugs.launchpad.net/percona-xtrabackup/+bug/1404484%5B/url%5D)  
if so then kindly click on the ‘affects me’ link so you will be notified as soon as updates to the bug is made.

---

<div class="post-metadata">

**Author:** ![turagittech](https://avatars.discourse-cdn.com/v4/letter/t/ba8739/32.png) [@turagittech](https://forums.percona.com/u/turagittech)\
**Post date:** [January 7, 2015, 4:49pm UTC](https://forums.percona.com/t/problem-with-master-info-when-creating-a-slave-from-an-existing-slave-with-xtrabackup/3975/3 "2015-01-07T16:49:35Z")

</div>

Thanks for that, yes it certainly looks the same, so I have done as you said

---

<div class="post-metadata">

**Author:** ![Zhah001](https://avatars.discourse-cdn.com/v4/letter/z/df788c/32.png) [@Zhah001](https://forums.percona.com/u/Zhah001)\
**Post date:** [February 18, 2015, 7:18am UTC](https://forums.percona.com/t/problem-with-master-info-when-creating-a-slave-from-an-existing-slave-with-xtrabackup/3975/4 "2015-02-18T07:18:06Z")

</div>

Hi all,  
I am very new to Percona and MySQL in general. I have a backup directory “2015-01-08 00-00-00” inside of which I see directories of all local database backups. I need to be able to restore one of the databases into another. How do I go about it?

Thanks,

* * *

outstanding experience with [amolife.com](http://amolife.com)

---

<div class="post-metadata">

**Author:** ![mirfan](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/mirfan/32/16890_2.png) [@mirfan](https://forums.percona.com/u/mirfan)\
**Post date:** [February 26, 2015, 3:09am UTC](https://forums.percona.com/t/problem-with-master-info-when-creating-a-slave-from-an-existing-slave-with-xtrabackup/3975/5 "2015-02-26T03:09:13Z")

</div>

Do you mean to restore database to another database e.g. restore test database to test1 database ? or you mean to restore single database from entire database server backup ? In case, If later is true, I would redirect you to my post [url][http://www.percona.com/blog/2014/12/09/mysql-5-6-transportable-tablespaces-best-practices/[/url]](http://www.percona.com/blog/2014/12/09/mysql-5-6-transportable-tablespaces-best-practices/%5B/url%5D) & documentation page on this [url][Percona XtraBackup](http://www.percona.com/doc/percona-xtrabackup/2.1/innobackupex/importing_exporting_tables_ibk.html%5B/url%5D)
