Make .unrecoverable a persistent one-way recovery quarantine

This commit is contained in:
Andrea Mazzoleni 2026-08-29 21:25:49 +02:00
parent ab26c7a056
commit 0f9ae3977c
46 changed files with 646 additions and 367 deletions

View file

@ -1856,13 +1856,16 @@ Known Issues
When `fix` cannot fully recover a damaged file, it quarantines it by
appending the `.unrecoverable` extension to its name.
Conversely, if a missing file is being fixed and a corresponding
`.unrecoverable` file already exists, SnapRAID assumes it is the result
of a previous incomplete recovery and resumes writing to it in-place.
If a later `fix` retries the recovery, it creates a new file under the
normal filename and preserves the old `.unrecoverable` file while recovery
is in progress. If the retry fails, the new failed result replaces the old
quarantine. If the retry succeeds completely, SnapRAID deletes the obsolete
`.unrecoverable` file. A quarantine is never promoted back to the normal
filename.
Because SnapRAID identifies quarantine files solely by their filename,
any pre-existing file that coincidentally uses the `.unrecoverable`
suffix may be truncated, overwritten, or replaced if its base name
suffix may be truncated, overwritten, replaced, or deleted if its base name
matches a file being fixed.
Avoid using the `.unrecoverable` extension for regular files, and ensure