high availability for slave node in pxc cluster

46 views
Skip to first unread message

Raja Kadali

unread,
Feb 12, 2018, 7:03:48 AM2/12/18
to Percona Discussion
Hi,
I've the following architecture,
node1 (Stand alone)
PXC (node2, node3, node4).

Node1(db1, db2) ----(mysql semi-sync replication for only db2)---------->node2(db2,db3).

in this, replication is between node1 and node2 of pxc. How can i make pxc cluster highly available for node1 for replication.

krunal....@percona.com

unread,
Feb 12, 2018, 11:04:19 PM2/12/18
to Percona Discussion
Hi Raja,

I presume you are looking at something like
- If node-2 (of pxc-cluster) goes off for some reason then replication from node-1 should be auto-moved to node-2

As of now, there is no automatic solution but the good part is since all the node of the cluster are in sync any other node
can start acting as a slave and catch up from the same point that was left off. (though this change-over has to be triggered manually).

Regards,
Krunal

Raja Kadali

unread,
Mar 12, 2018, 3:06:10 AM3/12/18
to Percona Discussion
Hi Krunal,
I'm facing one more issue in this architecture. I had switch off the machines for few days and started back. I'm getting the slave replication error in slaves that master has purged the gtids, which is required for replication. I cannot manually set the gtid_purged to the new position, because it needs to run the command "reset master" which is not allowed when the machines are in cluster. How do i get over this problem?

_________
Raja

Raja Kadali

unread,
Mar 14, 2018, 5:15:37 AM3/14/18
to Percona Discussion
Hi Krunal,
Any update on this.. 

krunal....@percona.com

unread,
Mar 14, 2018, 10:58:40 PM3/14/18
to Percona Discussion
* gtid_purged means the master is no more holding the data that probably slaves needs.
* I don't have any solution handy. Maybe checking MySQL blog space would help (this is something normal mysql use-space would encounter too).
* but the other alternative would be to re-setup the slave.

Regards,
Krunal

Raja Kadali

unread,
Mar 15, 2018, 2:54:12 AM3/15/18
to Percona Discussion
Hi Krunal,
Thanks for the update, But, i've found  one more alternate solution.
I've restored the backup of master to slave machines and fixed the gtid by inserting a skipping the  transaction using the GTID_NEXT command.

Yves Trudeau

unread,
Mar 15, 2018, 9:40:24 AM3/15/18
to percona-d...@googlegroups.com
Hi Krunal,
so, the other has been down for longer than expire_logs_days.
Only one option, backup the source, restore the destination and
re-bootstrap it.

Regards,

Yves
> --
> You received this message because you are subscribed to the Google Groups
> "Percona Discussion" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to percona-discuss...@googlegroups.com.
> To post to this group, send email to percona-d...@googlegroups.com.
> Visit this group at https://groups.google.com/group/percona-discussion.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/percona-discussion/1f72784e-edc4-4100-90f1-d5f4050ee1e0%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Experts" group.
> To post to this group, send email to exp...@percona.com.
> Visit this group at https://groups.google.com/a/percona.com/group/experts/.
>


--
Regards,

Yves
skype: y.trudeau
aim: ytrudeaumysql
Hangouts: yves.t...@percona.com
email: yv...@percona.com
Phone: (919) 650-6512

<http://www.google.com/url?q=http%3A%2F%2Ft.sidekickopen04.com%2Fe1t%2Fc%2F5%2Ff18dQhb0S7lC8dDMPbW2n0x6l2B9nMJW7t5XX48r4TL4N7d-5XdRJm5nW2zhqcR56dQS7f2Smy1z02%3Ft%3Dhttps%253A%252F%252Fwww.percona.com%252Flive%252F18%252F%26si%3D4752034298593280%26pi%3D049d59ac-7243-4aa4-d49f-bf1839794f52&sa=D&sntz=1&usg=AFQjCNFKEiiA14PjML3Aa52Eyc2USdqhuQ>
Percona Live 2018 Open Source Database Conference
<http://www.google.com/url?q=http%3A%2F%2Ft.sidekickopen04.com%2Fe1t%2Fc%2F5%2Ff18dQhb0S7lC8dDMPbW2n0x6l2B9nMJW7t5XX48r4TL4N7d-5XdRJm5nW2zhqcR56dQS7f2Smy1z02%3Ft%3Dhttps%253A%252F%252Fwww.percona.com%252Flive%252F18%252F%26si%3D4752034298593280%26pi%3D049d59ac-7243-4aa4-d49f-bf1839794f52&sa=D&sntz=1&usg=AFQjCNFKEiiA14PjML3Aa52Eyc2USdqhuQ>
April
23 - 25, 2018 Santa Clara,CA Get Your Ticket Now!, Inquire about
Sponsorship!

krunal....@percona.com

unread,
Mar 15, 2018, 10:56:31 PM3/15/18
to Percona Discussion
Perfect.

Let us know how it goes and any other problems if you face during operations.

Regards,
Krunal

Raja Kadali

unread,
Mar 16, 2018, 1:33:49 AM3/16/18
to Percona Discussion
Hi Yves,
Restoring the backup and rebootstrapping will work only if the slave is replicating all the databases, but if im replicating only a certain database, and there are other databases in the slave PXC. then I have to do partial backup and do the skip transaction.

_______
Raja 
Reply all
Reply to author
Forward
0 new messages