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
Recreate SQL Performance #2050
Comments
I guess there are two issues here:
Did the backup job had any errors before you deleted the database? Do you still have the log? |
SQLite is very slow specially in cases of large backups. when sqlite grows +600MB and more. Rebuilding database goes on and on.
Replacing sqlite with alternate centralized database should be taken in consideration specially for enterprise backup deployment. With this while configuring backups you need to choose between sqlite, mysql-db, etc |
Did the backup job had any errors before you deleted the database? Do you still have the log? this might be helpful to identify why the dblock files were downloaded and not just the dlist and dindex files... |
I think, that if queries will be hard to optimize, it will be better to process algorithms in c# object by linq. Centralized DBs are faster, but than it will not be compact portable solution. |
@jarfil : @saviodsouza : Do you have any references that shows SQLite is slow when the DB is larger than 600MB ? Everything inside Duplicati is using a standard @mnaiman : It will not be possible to do this with LinQ, as the databases are too large to fit in memory (which is why there are so many hoops to query directly on the data). |
…we need all the volumes anyway. This is an experiment related to #2050.
hi YES you are right I have traditional 'spinning-disk' 320 GB. Correct me if I am wrong. |
I also experienced slowness rebuilding the sqlite database. In my case the database is about 1.4GB and my backup holds ~800k files totaling ~200GB. I did a rebuild which didn't finish overnight. I'm running on a MacBook Pro with SSD and 16GB ram. I haven't done any research as to why it's slow but I'll look into it and see if I can come up with something more concrete. |
I've been running a rebuild since October 26th, which is showing no signs of finishing any time soon. :) |
Working with command line
its endless and each file is extreemly slow.
it would be showing some count. What are the possible reasons to re-download all the blocks to build the database? Secondly should support resuming of creating database. Regards, |
I have a similar problem, but it is the SQL verify step, which takes ages:
from log: The profiling log from the web interface shows:
some of these SELECT statements take approx 4h; some finish instantly. |
Same issue for me while recovering DB with v2.0.1.34 on Windows and FTP storage (box.com, Backup: 47.51 GB / 58 Versions / 1380 files): It didn't complete after 24h... Then I aborted and initialized a new full backup. |
I am collecting performance related issues under #2302 |
I'm seeing something similar - single core with 100% CPU and running for ages, not doing much. Since everyhing seems to be singlethreaded, it effectively blocks the entire duplicati application. If it's as simple as stated above to add a custom connect string, I beleive this should be done ASAP to allow those of us that want to use a real RDBMS to do so. SQLite3 is imho good for small stuff, but it really sucks on locking, which sesems to have struck this time. PostgreSQL does not have such an issue, and scales vastly better. MySQL/MariaDB/whateverfork also is far better, although I prefer PostgreSQL over them. |
@kenkendk When could be possible to implement the external DB connection string?
|
Allowing external databases isn't just about speed, it's also about integrity. sqlite is fine, but using something like postgresql is a lot safer, and faster, and allowing those of us that knows things a bit to customise this, would be very nice indeed. |
@rkarlsba |
I have:
Related issues: #1715 #1582 #1391 #1881 #1928
Version info
Duplicati Version: 2.0.1.28_canary_2016-10-19
Operating System: Windows 10 Pro x64
Backend: ACD
Bug description
Database recovery runs some crazy slow SQL queries that take over 10 minutes each.
Steps to reproduce
Actual result:
Expected result:
debug log
Suspects
The text was updated successfully, but these errors were encountered: