Skip to content

Conversation

@mayankshah1607
Copy link
Member

@mayankshah1607 mayankshah1607 commented Nov 27, 2025

K8SPXC-1576 Powered by Pull Request Badge

CHANGE DESCRIPTION

Support for backups using xtrabackup.

To enable this feature, set PXCO_FEATURE_GATES=BackupXtrabackup in the operator deployment.

CHECKLIST

Jira

  • Is the Jira ticket created and referenced properly?
  • Does the Jira ticket have the proper statuses for documentation (Needs Doc) and QA (Needs QA)?
  • Does the Jira ticket link to the proper milestone (Fix Version field)?

Tests

  • Is an E2E test/test case added for the new feature/change?
  • Are unit tests added where appropriate?
  • Are OpenShift compare files changed for E2E tests (compare/*-oc.yml)?

Config/Logging/Testability

  • Are all needed new/changed options added to default YAML files?
  • Are all needed new/changed options added to the Helm Chart?
  • Did we add proper logging messages for operator actions?
  • Did we ensure compatibility with the previous version or cluster upgrade process?
  • Does the change support oldest and newest supported PXC version?
  • Does the change support oldest and newest supported Kubernetes version?

Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
@pull-request-size pull-request-size bot added the size/XXL 1000+ lines label Nov 27, 2025
mayankshah1607 and others added 9 commits November 28, 2025 10:20
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
Signed-off-by: Mayank Shah <[email protected]>
}

switch cfg.Type {
case BackupStorageType_GCS:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about PVC backup? Will we support this type? In PXCO we have it.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm, I'm not sure we can support it. With SST, backup occurs on the job pod, so we create new PVC and mount it on the job and take backup there.

But now the architecture is different - the backup process occurs alongside pxc in a sidecar. So we cannot dynamically mount/unmount new PVC like we do in sst with a job. I'm not sure how we can implement PVC backups, we need to think about it maybe as a separate task. Maybe we can consider using VolumeSnapshots

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, we can do it via separate PR (not now)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One more trick I think we can try - since xtrabackup allows you to output a tar stream, we can stream that data from stdout to a grpc channel on another job. Then similar to our current approach, the job will mount the PVC and rebuild the backup data from the tar received over the stream.

To maintain consistency with s3 and azure, the job can similarly read xbstream from the grpc channel and run xbcloud there.

I think it is possible. Maybe we can use that approach in PS operator as well. Anyway, let's tackle it in a separate task.

@JNKPercona
Copy link
Collaborator

Test Name Result Time
auto-tuning-8-0 passed 00:18:37
allocator-8-0 passed 00:11:44
backup-storage-tls-8-0 passed 00:22:43
cross-site-8-0 passed 00:33:48
custom-users-8-0 passed 00:11:26
demand-backup-cloud-8-0 passed 00:56:04
demand-backup-encrypted-with-tls-8-0 passed 00:45:20
demand-backup-8-0 passed 00:42:44
demand-backup-flow-control-8-0 passed 00:10:15
demand-backup-parallel-8-0 passed 00:09:08
demand-backup-without-passwords-8-0 passed 00:15:24
haproxy-5-7 passed 00:14:19
haproxy-8-0 passed 00:14:27
init-deploy-5-7 passed 00:15:54
init-deploy-8-0 passed 00:16:42
limits-8-0 passed 00:11:59
monitoring-2-0-8-0 passed 00:22:13
monitoring-pmm3-8-0 passed 00:17:37
one-pod-5-7 passed 00:14:35
one-pod-8-0 passed 00:13:48
pitr-8-0 passed 00:43:20
pitr-gap-errors-8-0 passed 00:54:57
proxy-protocol-8-0 passed 00:09:08
proxy-switch-8-0 passed 00:13:26
proxysql-sidecar-res-limits-8-0 passed 00:08:30
proxysql-scheduler-8-0 passed 00:16:05
pvc-resize-5-7 passed 00:14:32
pvc-resize-8-0 passed 00:16:45
recreate-8-0 passed 00:16:51
restore-to-encrypted-cluster-8-0 passed 00:25:32
scaling-proxysql-8-0 passed 00:08:17
scaling-8-0 passed 00:10:30
scheduled-backup-5-7 passed 01:05:26
scheduled-backup-8-0 passed 01:02:37
security-context-8-0 passed 00:25:22
smart-update1-8-0 passed 00:32:32
smart-update2-8-0 passed 00:37:15
storage-8-0 failure 00:42:45
tls-issue-cert-manager-ref-8-0 passed 00:08:29
tls-issue-cert-manager-8-0 passed 00:09:44
tls-issue-self-8-0 passed 00:13:16
upgrade-consistency-8-0 passed 00:22:51
upgrade-haproxy-5-7 passed 00:23:59
upgrade-haproxy-8-0 passed 00:23:48
upgrade-proxysql-5-7 passed 00:13:37
upgrade-proxysql-8-0 passed 00:14:22
users-5-7 passed 00:25:19
users-8-0 passed 00:24:46
validation-hook-8-0 passed 00:01:47
Summary Value
Tests Run 49/49
Job Duration 02:48:16
Total Test Time 18:25:00

commit: 91588dd
image: perconalab/percona-xtradb-cluster-operator:PR-2274-91588dd2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/XXL 1000+ lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants