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

Allow to setup and configure the backup strategy #393

Open
christofmuc opened this issue Jan 19, 2025 · 0 comments
Open

Allow to setup and configure the backup strategy #393

christofmuc opened this issue Jan 19, 2025 · 0 comments
Labels
enhancement New feature or request

Comments

@christofmuc
Copy link
Owner

The question came up - KnobKraft seems to create crazy amounts of backups in the Database folder, how can I clean it up?

Answer: As of version 1.10.x, there is a hardcoded back up and back up cleanup strategy.

Backups - are done for the current database every time KnobKraft is closed, in the same directory as the database file itself, with a postfix -backup(number).

The rule for the database backup files currently is - delete old backups until there are either only 3 backups left or the total size of the backups is less than 500 MByte.

Note the 500 MByte limit is for each database. So e.g. if you have 3 different databases for 3 different setups (whyever), the total size of the backups will be 1500 MByte.

Additional backups are created on database migration (only happens when the database schema is changed due to new version's features). Those migration backups are never deleted automatically, as you might need them for using the old KnobKraft version.

I am sure this is going into the preferences soon, but this is state as of v1.10.x.

The respective code can be found here:

https://github.com/christofmuc/MidiKraft-database/blob/master/PatchDatabase.cpp

function "manageBackupDiskspace".

Originally posted by @christofmuc in #68

@christofmuc christofmuc added the enhancement New feature or request label Jan 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant