# Best practices for backup strategy on a 3-node cluster

**URL:** <https://forums.percona.com/t/best-practices-for-backup-strategy-on-a-3-node-cluster/32970>\
**Category:** Percona XtraDB Cluster\
**Created:** [September 6, 2024, 3:28pm UTC](https://forums.percona.com/t/best-practices-for-backup-strategy-on-a-3-node-cluster/32970 "2024-09-06T15:28:05Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![eprevost](https://avatars.discourse-cdn.com/v4/letter/e/ed655f/32.png) [@eprevost](https://forums.percona.com/u/eprevost)\
**Post date:** [September 6, 2024, 3:28pm UTC](https://forums.percona.com/t/best-practices-for-backup-strategy-on-a-3-node-cluster/32970/1 "2024-09-06T15:28:05Z")

</div>

Hi,

I’m new to XtraDB cluster (or any Galera flavor). I’m trying to figure out a backup strategy for a cluster.

My backup schedule would look like this:

- Weekly Full backup with xtrabackup
- Daily differential backup with xtrabackup
- binary log backup every 15 minutes.

Assuming I have a cluster composed of nodes A, B and C, and users may do writes on nodes A and B, on which node should I take the backups?

I was thinking about taking backups on node C. Would I need to to set log\_slave\_update=1 to have all transactions in the binary log?

If node C goes down and I need to move backup job to node A or B, do I need to start a whole new set of full/diff/binlog backup or full backup from node C can be used a base for differential backup on node A/B? I feel like we can’t mix and match backups and binary logs from different nodes…

Thank you!

---

<div class="post-metadata">

**Author:** ![matthewb](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/matthewb/32/34_2.png) [@matthewb](https://forums.percona.com/u/matthewb)\
**Post date:** [September 6, 2024, 3:54pm UTC](https://forums.percona.com/t/best-practices-for-backup-strategy-on-a-3-node-cluster/32970/2 "2024-09-06T15:54:50Z")

</div>

Hey @eprevost,  
Best practice is to take backups from your writer node. Since you are in a cluster, you can take them from C as well. `log_slave_updates=1` should be set, yes, so that Galera-based transactions are re-written to C’s binary log. I believe this is already the default in 8.0.

If C goes down, it would be far easier to start a whole new set of backups from A or B. In theory, you only need 1 set of binlogs because GTIDs help mitigate any filename/position offset issues.

---

<div class="post-metadata">

**Author:** ![eprevost](https://avatars.discourse-cdn.com/v4/letter/e/ed655f/32.png) [@eprevost](https://forums.percona.com/u/eprevost)\
**Post date:** [September 6, 2024, 5:32pm UTC](https://forums.percona.com/t/best-practices-for-backup-strategy-on-a-3-node-cluster/32970/3 "2024-09-06T17:32:26Z")

</div>

Thank you!

So, as long as log\_slave\_updates is enabled on all nodes, all transactions will be in binary logs of all nodes with the same GTID, but binary log file names may differ. But could the be in different order? Example: node C has GTID G1 followed by G2 in its binlog, could node A has have G2 then G1 instead?

---

<div class="post-metadata">

**Author:** ![matthewb](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/matthewb/32/34_2.png) [@matthewb](https://forums.percona.com/u/matthewb)\
**Post date:** [September 6, 2024, 5:53pm UTC](https://forums.percona.com/t/best-practices-for-backup-strategy-on-a-3-node-cluster/32970/4 "2024-09-06T17:53:48Z")

</div>

No, because GTIDs have a sequence to them (the part after the `:`). They can’t be out of order.
