-
Notifications
You must be signed in to change notification settings - Fork 1.7k
restic stats is unreasonably slow in comparison to other operations #2126
Copy link
Copy link
Open
Labels
category: optimizationcategory: statstype: feature enhancementimproving existing featuresimproving existing features
Description
Output of restic version
restic 0.9.3 compiled with go1.11.1 on linux/amd64
How did you run restic exactly?
restic stats --mode restore-size
What backend/server/service did you use to store the repository?
Local disk.
Expected behavior
This mode should take no longer than the part of restic prune that finds unused objects (about 15-20 minutes on this repository).
Actual behavior
This analysis takes multiple hours.
Do you have any idea what may have caused this?
My suspicion was that, while restic prune's unused-object discovery mechanism prunes trees that have already been marked as used, restic stats on the other hand did not prune any subtrees and therefore has to recompute the size of each tree each time it is encountered.
However, looking through the source code, it seems that this is attempted? Perhaps this code is not functioning correctly?
Do you have an idea how to solve the issue?
Not without digging into the source code more.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
category: optimizationcategory: statstype: feature enhancementimproving existing featuresimproving existing features