# Percona XtraDB Cluster backup retention not working as expected

**URL:** <https://forums.percona.com/t/percona-xtradb-cluster-backup-retention-not-working-as-expected/28185>\
**Category:** Percona XtraDB Cluster 5.x\
**Created:** [February 1, 2024, 10:44pm UTC](https://forums.percona.com/t/percona-xtradb-cluster-backup-retention-not-working-as-expected/28185 "2024-02-01T22:44:32Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![santosh240](https://avatars.discourse-cdn.com/v4/letter/s/aca169/32.png) [@santosh240](https://forums.percona.com/u/santosh240)\
**Post date:** [February 1, 2024, 10:44pm UTC](https://forums.percona.com/t/percona-xtradb-cluster-backup-retention-not-working-as-expected/28185/1 "2024-02-01T22:44:32Z")

</div>

Hi Team,  
We have installed the MySQL cluster using the Percona-xtradb-cluster-operator in redhat Openshift cluster. I have configured to backup the database to S3 storage and backup is working fine but retention I kept only 1 but it is not keep accumulating the database backups in S3 storage. As per configuration it should have 1 copy for previous day and other one is current backup.  
RedHat Openshift Version: 4.8.25  
percona-xtradb-cluster-operator version: 1.11.0  
MySQL DB version: mysql Ver 14.14 Distrib 5.7.35-38

Here is the Backup configuration updated in operator and which is creating job to run the backup successfully but retention is not working as per config.

Am I missing any configuration to get the retention working in backup config? Please suggest.  
I have configured value 1 for key under schedule.

backup:  
image: ‘percona/percona-xtradb-cluster-operator:1.11.0-pxc5.7-backup’  
schedule:  
- keep: 1  
name: daily-backup  
schedule: 0 13 \* \* \*  
storageName: s3-backup  
storages:  
s3-backup:  
s3:  
bucket:   
credentialsSecret:   
endpointUrl:   
region:   
type: s3  
verifyTLS: false

---

<div class="post-metadata">

**Author:** ![santosh240](https://avatars.discourse-cdn.com/v4/letter/s/aca169/32.png) [@santosh240](https://forums.percona.com/u/santosh240)\
**Post date:** [February 20, 2024, 12:40am UTC](https://forums.percona.com/t/percona-xtradb-cluster-backup-retention-not-working-as-expected/28185/2 "2024-02-20T00:40:12Z")

</div>

Can you please provide me an update on this.
