Report of "backup --force" lists all files as "new"

#1

Using backup with “–force” showed all files as new here (in fact only one file was changed since last snapshot)

A testcase with a directory containing 1 (empty) file listed reproducible both the file and the dir as new after subsequent backup operations with “–force”,

Files:           1 new,     0 changed,     0 unmodified
Dirs:            1 new,     0 changed,     0 unmodified
Added to the repo: 0 B

while without “–force” everything is classified as unmodified:

Files:           0 new,     0 changed,     1 unmodified
Dirs:            0 new,     0 changed,     1 unmodified
Added to the repo: 0 B

restic_0.9.5_windows_amd64.exe, NTFS file system

Is this intended bahaviour?

(diff-operations on the snapshots of the original use case showed expected output - only known modifications listed)

#2

New/changed/unmodified metrics compare the new snapshot to the parent snapshot. When you use --force, you are telling restic not to use a parent snapshot at all; therefore all files are classified as new.

This does not mean that the file contents are not being deduplicated. Note Added to the repo: 0 B in both cases.

1 Like
#3

Thanks for the explanation.

1 Like