-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Verify pack files before upload #4529
Comments
This would be great. If the corruption is detected before the upload what action should restic take in your opinion ? Skip some files and warn the user ? Entirely abort the backup ? The second option could prevent people from performing the backup in cases like the issue #4523, but is probably safer. In the first option it would be useful to print all the files that were not backed up, this would have allowed me to immediately check if those files were important to me or not without waiting for restic check --read-data, and if the files where important i could have backed them up without restic while waiting for a fix. |
I'm currently leaning towards calling It might be possible to print which files restic is currently processing, although I'm not sure how hard it would be to implement that. |
If there is a risk of damaging the entire repository i agree, it's better to abort. Thank you. |
While discussing with @rawtaz, we've arrived at a few interesting points.
As I've just noticed, it would be possible to verify a new blob immediately in |
whatever the outcome here, as a user i appreciate your level of attention and care. thank you :) |
While debugging #4677 and #4523, it turned out that we need a simple way to determine the problematic file. As such we need good error reporting, such that #4681 implements the alternative that I've sketched in my previous comment. #4686 will extend the error reporting to include the required information. |
Output of
restic version
0.16.0
What should restic do differently? Which functionality do you think we should add?
restic should fully decode and verify all blobs in a pack file before uploading to make sure that no data corruption has happened.
This will ensure that the encryption and compression did not damage the blobs.
What are you trying to do? What problem would this solve?
Would have detected the data corruption in #4523 during the backup.
A lot of the data corruption issues listed in https://forum.restic.net/t/study-of-repository-damage-types/5202 would likely also be preventable by this check.
The text was updated successfully, but these errors were encountered: