Lstat errors on a long running backup


I’m backing up a very large filesystem (which takes hours), which is changing whilst its being backed up, and that’s known and okay, but we do get occasional errors like:

error: lstat <file> no such file or directory

which cause restic to exit with a non-zero exit code, and our wrapper script then reports to monitoring that the backup failed.

I’m wondering if the new --no-scan flag in 0.15 would change this behavior, or if its literally a race condition between the file being found and opened for backup, rather than the file being found in the scan much earlier and then not being there when the its attempted to be read some time later.



why not simply try the new flag? :thinking:

This is Ignore disappeared source files · Issue #3098 · restic/restic · GitHub , which is usually a harmless warning. And no the --no-scan flag won’t help.

Thanks for the update Michael! Will look at popping the --no-scan flag in anyway when we upgrade to 0.15.0, coz we’re running headless so don’t care about ETA but do care about time.

And thanks for a great bit of code!