Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

max_backup_count should keep valid backups #607

Open
Skunnyk opened this issue Aug 3, 2023 · 1 comment · May be fixed by #778
Open

max_backup_count should keep valid backups #607

Skunnyk opened this issue Aug 3, 2023 · 1 comment · May be fixed by #778
Assignees
Labels
review Issues in the state 'review'

Comments

@Skunnyk
Copy link
Contributor

Skunnyk commented Aug 3, 2023

Project board link

If for any reasons your backups fails, the medusa purge task will delete what you have configured in max_backup_count, without taking the status in account.
So you can end up with only incompletes backups:

max_backup_count = 5:

$ medusa list-backups
[2023-07-26 17:41:44,995] INFO: Found credentials in shared credentials file: /etc/medusa/credentials-s3
scylladb01-production-20230719-1100 (started: 2023-07-19 11:00:40, finished: Incomplete [0 of 6 nodes finished])
scylladb01-production-20230721-1100 (started: 2023-07-21 11:01:24, finished: Incomplete [0 of 6 nodes finished])
scylladb01-production-20230723-1100 (started: 2023-07-23 11:00:55, finished: Incomplete [0 of 6 nodes finished])
scylladb01-production-20230724-1100 (started: 2023-07-24 11:01:20, finished: Incomplete [0 of 6 nodes finished])
scylladb01-production-20230725-1100 (started: 2023-07-25 11:00:43, finished: Incomplete [0 of 6 nodes finished])

In this case, we don't have any valid backup due to the purge, only incomplete ones.

We may be able to keep max_backup_count valid backups after a purge. Not sure how to implement that btw.

Yes I know, the real solution is to avoid failed backups :D

@adejanovski adejanovski added the new Issues requiring triage label Aug 3, 2023
@rzvoncek rzvoncek removed new Issues requiring triage to-groom labels Mar 5, 2024
@adejanovski adejanovski added the ready Issues in the state 'ready' label Mar 6, 2024
@rzvoncek rzvoncek self-assigned this Mar 27, 2024
@adejanovski adejanovski added in-progress Issues in the state 'in-progress' and removed ready Issues in the state 'ready' labels Mar 27, 2024
@adejanovski adejanovski added ready-for-review Issues in the state 'ready-for-review' review Issues in the state 'review' and removed in-progress Issues in the state 'in-progress' ready-for-review Issues in the state 'ready-for-review' labels Mar 28, 2024
@adejanovski adejanovski added in-progress Issues in the state 'in-progress' and removed review Issues in the state 'review' labels Jun 13, 2024
@rzvoncek rzvoncek linked a pull request Jun 13, 2024 that will close this issue
@adejanovski adejanovski added review Issues in the state 'review' and removed in-progress Issues in the state 'in-progress' labels Jun 13, 2024
@rzvoncek
Copy link
Contributor

I've followed up on @adejanovski 's review and reimplemented the solution in a meaningfully simpler way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
review Issues in the state 'review'
Projects
None yet
3 participants