Database file size after repair/recreation (1000x bigger)

Hello,
I was testing Duplicati ability to restore database (to be sure it is working :slight_smile: ). Good news is, it is working.

But the original DB file was 420 KB big, but after restore the DB file is 420 MB. Is ti expected behaviour? Why is this happening? Is there any way to shrink it back to 420 KBs?

For info my backup is around 130 GBs with 15 versions (smart retention, oldest is 8 months old).

Thank you for any info/help :slight_smile:

EDIT: Tried vacuum, it only shrinked the file to 395 MB.

Welcome to the forum @Foqala

Seems way too tiny. At default 100 KB blocksize, that job’s database has to track 1.3 million blocks of 130 GB backup, and also hold every pathname (with deduplication across versions and for duplicated folders).

Unusual situations might be able to track 130 GB in 420 KB, but it would need quite big files and blocksize.

How the backup process works gets into this. Did you keep the old database so you can compare to new?
Beyond mere size, one can also look at these with DB Browser for SQLite or similar to check the content.

Could have been bad news if it did not, so it’s safer to keep the old database until you prove the Recreate.
I actually considered putting in a request for enhancement on that, but developers are scarce these days.
If there are any people out there who could help with code, test, docs, support, etc., it would be wonderful.

1 Like

Hello,

thanks a lot for answer. Yeah, the DB Browser was good idea. It seems I had (for some reason) a bad version of the database (the original one - 420 kb). It was basically empty. But I had older backups and there is correct one (420 MBs). So it was probably all my mistake when I was messing with backups and databases :slight_smile:

And regarding the DB backups, this is mainly testing setup, where I was “trying” to broke it to see, what to expect from Duplicati. But so far it is the best and most reliable backup solution I tried :slight_smile:

2 Likes

If you have an interest in trying to break it, the Duplicati project could benefit greatly from those who can do that while keeping enough logs and other notes that it can be studied, reproduced, and possibly fixed by developers.

I’m pleased to hear your good results compared to others tried. Duplicati isn’t perfect, but I suspect none are…