deviantony / xtrabackup-scripts

Wrapper scripts (Python) for the Percona Xtrabackup tool.
http://www.percona.com/doc/percona-xtrabackup
110 stars 46 forks source link

Manage backup retention #2

Open prigal opened 9 years ago

prigal commented 9 years ago

Hi, I found your script this morning and started using it (filesystem version). It's ok, I just have to put the command line in my hourly/daily/weekly/monthly to keep several versions of my database.

But, have you written any script to define a strategy on backups, like :

That will save me some time on writing it :)

Thanks for your work.

deviantony commented 9 years ago

Sure, I have my own scripts for backup retentions in my company, but they depend on our backup policy and mainly use the find command to remove the useless backups.

deviantony commented 9 years ago

This question raises another one in my head: should the backup retention be implemented inside this project? For the moment I can say:

Pros:

Cons:

I will let this issue open and continue to think about it.

jalogisch commented 9 years ago

Hej,

just stumbled over this nice toolset. Data Rotation should be out of scope, because everyone has different needs.

The only i would think of is creating a "how it could be implemented" - or something "this is how i handle this" in the Readme.

This will bring the people to think about such points and not just fire and forget some scripts and complain after a crash that the default policies did not help them.

For example i had to implement a "lock" to do not backup if the file /tmp/do_not_backup_db is present because of other jobs in the filesystem and the database are running. Additional i had to start a new Backup after one is finished - the Data in this DB are marked as of high business value.

But thats just my 2 cent.