dropbox / dbxcli

A command line client for Dropbox built using the Go SDK
Other
1.04k stars 102 forks source link

Error post upload_session/append_v2 connection reset by peer #211

Open jaraco opened 2 weeks ago

jaraco commented 2 weeks ago

I'm attempting to upload a large file (96GB) using dbxcli. So far twice it's failed with the following error:

Error: Post https://content.dropboxapi.com/2/files/upload_session/append_v2: read tcp [2600:<elided>]:50250->[2620:100:601c:14::a27d:60e]:443: read: connection reset by peer

The process exits with a code of 255. Retrying the command restarts from scratch. It's failed twice this way. I'm unsure if the issue is intermittent or repeatable. I'm unsure how much was uploaded before it failed (the progress indicator is overwritten by the error).

It would be nice if the implementation was resistant to this sort of error.

jaraco commented 2 weeks ago

I re-attempted the upload a third time, this time passing -v and redirecting the output to a file:

 @ dbxcli put -v large_file  Documents/large_file 2> ~/put.log

And this time, it completed without error. So the issue does appear to environmental. Perhaps the connection was getting dropped merely because I was running overnight and Verizon was rebooting IPv6 routers. Or maybe letting the system be idle for long periods allowed it to go to some low power state and lose the connection. I am using a headless mac mini, so I know it hasn't gone to sleep (because I can re-connect to it on demand).

Regardless, it would still be nice if dbxcli could retry a dropped connection and not lose the progress.