Do not delete target file on gateway error

Some really huge files cause at the very end of the transmission a 504 Gateway Error from the WebDAV server:

2021/01/12 12:23:08 INFO :
Transferred: 584.484G / 1019.652 GBytes, 57%, 2.984 MBytes/s, ETA 1d17h28m57s
Checks: 387 / 387, 100%
Transferred: 5 / 21, 24%
Elapsed time: 55h43m0.5s
Transferring:

  • EF/…SK16 DE EN IMDB8.4.mkv:100% /73.060G, 366.813k/s, 0s

2021/01/12 12:23:16 DEBUG : pacer: low level retry 1/10 (error 504 Gateway Timeout)
2021/01/12 12:23:16 DEBUG : pacer: Rate limited, increasing sleep to 2s
2021/01/12 12:23:17 DEBUG : pacer: Reducing sleep to 1.5s
2021/01/12 12:23:17 DEBUG : EF/...FSK16 DE EN IMDB8.4.mkv: Received error: 504 Gateway Timeout - low level retry 8/10

2021/01/12 12:23:18 INFO :
Transferred: 584.484G / 1.067 TBytes, 53%, 2.984 MBytes/s, ETA 2d26m58s
Checks: 387 / 387, 100%
Transferred: 5 / 21, 24%
Elapsed time: 55h43m10.5s
Transferring:

  • EF/…SK16 DE EN IMDB8.4.mkv: 0% /73.060G, 0/s, -

I don't know why the error happens (server not controlled by me), but this is how it is logged through the Nextcloud Activity tab (created, deleted, created, deleted...):

For me it looks like it was fully created, but because of the error, rclone deletes it afterwards. Correct?

If yes, is it possible to ignore such errors and leave the file on the server (I would compare checksums in a second rclone process)?

There is an issue about this

I just posted a potential fix

Can you give it a go?

I'm using Slackware / Unraid so I think I need to wait for an official beta release?!

If you can find where the plugin keeps the rclone binary, you can replace it with the one from above. I don't know anything about Slackware / Unraid though!

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.