Comment 12 for bug 1734144

Revision history for this message
Kenneth Loafman (kenneth-loafman) wrote : Re: [Bug 1734144] Re: swift $file was corrupted during upload even with retries

I have committed the patch supplied as a partial fix. I really need a
Swift user to code and test the suggested -1 fix.

On Wed, Apr 4, 2018 at 3:01 AM, Joris van Eijden <<email address hidden>
> wrote:

> A size of -1 indicates that the backend server responded with a 404
> "file not found" to a HEAD request to get the uploaded file's size.
>
> You might be able to "fix" that by patching the _put method in
> duplicity/backends/swiftbackend.py to:
> 1. Check the local file size before uploading.
> 2. Put the 'self.conn.put_object' in a try/catch block.
> 3. Check the remote file size after uploading by calling the _query method
> inside another try/catch block.
> 4. Retry the upload if either an exception occurs or the file size doesn't
> match.
>
> --
> You received this bug notification because you are a bug assignee.
> https://bugs.launchpad.net/bugs/1734144
>
> Title:
> swift $file was corrupted during upload even with retries
>
> Status in Duplicity:
> In Progress
>
> Bug description:
> Command:
>
> duplicity --verbosity 4 --log-file /var/log/duplicity.log --volsize 25
> --tempdir="/tmp" --file-prefix="app1.server8." --name="app1.server8."
> --exclude-device-files --allow-source-mismatch --num-retries 100
> --exclude-filelist=/etc/cloudvps-boss/exclude.conf --full-if-older-
> than="7D" --no-encryption / swift://cloudvps-boss-backup
>
> The backup halts with this error:
>
> ERROR 44 'app1.server8.duplicity-full.20171122T021711Z.vol741.difftar.gz'
> 26197773 -1
> . File app1.server8.duplicity-full.20171122T021711Z.vol741.difftar.gz
> was corrupted during upload.
>
>
> I would suspect it to restart (due to --num-retries 100), but that does
> not happen.
>
> Duplicity version: 0.7.15 (from source)
> Ubuntu 16.04 with that default python (2.7..)
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/duplicity/+bug/1734144/+subscriptions
>