rustic-rs / rustic

rustic - fast, encrypted, and deduplicated backups powered by Rust
https://rustic.cli.rs
Apache License 2.0
1.86k stars 71 forks source link

Stability in case of power failure etc. #151

Closed elgatobavaria closed 2 years ago

elgatobavaria commented 2 years ago

Hi guys, i would like to know how the stability is compared to "Restic" in case of power failure during any process running with "Rustic". One time during backup with restic it crashed because of a lighning strike in our neibourhood. The repo was locked but after unlocking it by hand i was able to backup / restore as usual.

Go on with this great project :-) Best regards Mathias

aawsome commented 2 years ago

With respect to pack files, index files and snapshot files rustic behaves exactly like restic and only writes files if the depending files are finished with writing.

This ensures that if a backup run produces an additional snaphot, it is a sane one.

Moreover, a backup run only adds data and is never able to invalidate any previously made snapshot.

Rustic only differs w.r.t. lock files: As rustic is designed completely lock-free, there are no lock files written and stale locks cannot appear.

aawsome commented 2 years ago

What I should also mention is that rustic - as restic - saves intermediate index files for packs already written. So, resuming from an aborted backup does not need to re-save all blobs to the backend.

I don't see any shortcomings of rustic with respect to power failures or aborted backups. Therefore I'll close this issue. If you or anyone encounters any problems, feel free to re-open the issues.

If there are more questions about rustic's behavior the discussions is also a good place to start.