duplicity backup fails with Error -3 while decompressing data: invalid literal/length code
This is the error message I get, when I run the backup GUI tool for duplicity:
Failed to read /tmp/duplicity-4i02w2cf-tempdir/mktemp-20izc2jy-2: (<class 'zlib.error'>, error('Error -3 while decompressing data: invalid literal/length code'), <traceback object at 0x7fb9565b72c0>)
Files in /.cache/deja-dup/723386a63f5e590e28c04222e42fd44a look ok. I can uncompress/untar the all sigtar.gz files. The manifest Files also look ok to me. Storage has enough space.
Backup is done on a Synology NAS with smb mount. The last files there are:
rwx------+ 1 tuxedo users 26205721 Feb 22 09:00 duplicity-inc.20210221T111511Z.to.20210222T075435Z.vol29.difftar.gz
-rwx------+ 1 tuxedo users 26221784 Feb 22 09:00 duplicity-inc.20210221T111511Z.to.20210222T075435Z.vol30.difftar.gz
-rwx------+ 1 tuxedo users 14020082 Feb 22 09:01 duplicity-inc.20210221T111511Z.to.20210222T075435Z.vol31.difftar.gz
-rwx------+ 1 tuxedo users 6774844 Feb 22 09:01 duplicity-new-signatures.20210221T111511Z.to.20210222T075435Z.sigtar.gz
-rwx------+ 1 tuxedo users 32576 Feb 22 09:01 duplicity-inc.20210221T111511Z.to.20210222T075435Z.manifest
-rwx------+ 1 tuxedo users 262128 Feb 23 11:02 duplicity-new-signatures.20210222T075435Z.to.20210223T072856Z.sigtar.gz
-rwx------+ 1 tuxedo users 131072 Feb 23 11:02 ~gvfVbgn.tmp
-rwx------+ 1 tuxedo users 524256 Feb 23 11:20 ~gvf1oNZ.tmp
The last sigtar.gz file on the NAS is corrupt:
tar tzf duplicity-new-signatures.20210222T075435Z.to.20210223T072856Z.sigtar.gz
snapshot/home/ppe/
snapshot/home/ppe/.WindowsVM/machina/
snapshot/home/ppe/.WindowsVM/machina/Logs/
signature/home/ppe/.WindowsVM/machina/Logs/VBox.log
signature/home/ppe/.WindowsVM/machina/Logs/VBox.log.1
signature/home/ppe/.WindowsVM/machina/Logs/VBox.log.2
signature/home/ppe/.WindowsVM/machina/Logs/VBox.log.3
signature/home/ppe/.WindowsVM/machina/Snapshots/{9193bbcd-0238-461f-8433-32837672cf00}.vdi
gzip: stdin: invalid compressed data--format violated
tar: Unexpected EOF in archive
tar: Error is not recoverable: exiting now
It belongs to a virtualbox VM. It was probably running while the backup was running.
I moved the corrupt file away and restarted the backup. It seems to work fine now and it backups the missing files from the corrupt sigtar file!
Please add a simple way for normal users to cleanup corrupt sigtar files on the Backup folder, instead of reporting that error message. Something like:
If a file is corrupt: skip it when doing backups - perhaps mark it as 'corrupt', but keep it. In case of restore: try to restore from the file (it might restore partial data), then go to next file.