yadayada / acd_cli

An unmaintained command line interface and FUSE filesystem for Amazon (Cloud) Drive
Other
1.35k stars 165 forks source link

RequestError: 400 {"message":"Cannot complete upload"} & RequestError: 400 {"message":"Cannot read from request."} #566

Closed Tangoes closed 7 years ago

Tangoes commented 7 years ago

I am having pretty of this:

17-05-25 18:03:26.813 [ERROR] [acd_cli] - Uploading "Somefilebiggerthan12GB.Ext" failed. RequestError: 400, {"message":"Cannot read from request."}.
17-05-25 18:03:26.824 [WARNING] [acdcli.api.backoff_req] - Waiting 8.949362s because of error(s).
17-05-25 18:05:36.175 [ERROR] [acd_cli] - Uploading "Somefilebiggerthan12GB.Ext" failed. RequestError: 400, {"message":"Cannot complete upload"}.
17-05-25 18:05:36.187 [WARNING] [acdcli.api.backoff_req] - Waiting 47.968202s because of error(s).

I am using new acd and api: acd_cli 0.3.2, api 0.9.3 after a fresh install.

No file bigger than 1GB is uploading for me. I dont know why.

UPDATE: I have a new kind of error: RequestError: 1000, ('Connection aborted.', OSError("(104, 'ECONNRESET')",)).

After 24 hours (or less) I´ve discovered that some files are correctly uploaded but the files that has those errors, dont. So I´ve been 24 hours (or less) to upload 11 files, because after the time the file is uploading, if I got the error, the file upload fails...

Today I deleted my BD and trying again...

I will try just upload, no flags.

acdcli upload /home/file.mkv /incoming/

File info: Name: file.mkv size: 12.5 GB

Let´s see...

Fails.

[root@server]# acdcli upload acdcli upload /home/file.mkv /incoming/
17-05-26 17:50:10.009 [ERROR] [acd_cli] - Uploading "file.mkv" failed. RequestError: 400, {"message":"Cannot read from request."}.
[                         ]   0.0% of   12GiB  0/1   -4.4GB/s       0s
1 file(s) failed.
[root@server]#

700 MB file:

[root@server]# acdcli upload acdcli upload /home/file700.mkv /incoming/

[#########################] 100.0% of 703MiB 1/1 0.0B/s 0s

Ok.

3 GB file:

And fails again.

17-05-26 18:14:57.552 [ERROR] [acd_cli] - Uploading "file3GB.mkv" failed. RequestError: 400, {"message":"Cannot complete upload"}.
[                         ]   0.0% of    3GiB  0/1 -882.0MB/s       0s
1 file(s) failed.

Fails. What a f***k is going on.

17-05-26 18:23:48.171 [ERROR] [acd_cli] - Uploading "file1gb.mkv" failed. RequestError: 400, {"message":"Cannot read from request."}.
[                         ]   0.0% of    1GiB  0/1 -366.6MB/s       0s
1 file(s) failed.

Trying with other ACD account:

Nah, it´s not -one- ACD account issue, the same with other ACD account.

17-05-26 18:31:50.042 [ERROR] [acd_cli] - Uploading "file1gb.mkv" failed. RequestError: 400, {"message":"Cannot read from request."}.
[                         ]   0.0% of    1GiB  0/1 -353.4MB/s       0s
1 file(s) failed.

Verbose output:


[root@server acd_cli]# acdcli -v upload /1gbfile.mkv /incoming/ 
17-05-26 18:47:38.863 [INFO] [acd_cli] - Plugin leaf classes: TestPlugin
17-05-26 18:47:38.863 [INFO] [acd_cli] - TestPlugin attached.
17-05-26 18:47:38.863 [INFO] [acd_cli] - Settings path is "/root/.config/acd_cli".
17-05-26 18:47:38.864 [INFO] [acd_cli] - Cache path is "/root/.cache/acd_cli".
17-05-26 18:47:38.865 [INFO] [acdcli.api.client] - Initializing ACD with path "/root/.cache/acd_cli".
17-05-26 18:47:38.865 [INFO] [acdcli.api.oauth] - AppspotOAuthHandler initialized
17-05-26 18:47:39.362 [INFO] [acdcli.cache.schema] - DB schema version is 2.
17-05-26 18:47:39.362 [INFO] [acd_cli] - Last sync at 2017-05-26 16:43:31.314720.
17-05-26 18:47:39.363 [INFO] [acd_cli] - Resolved "/incoming" to "Node('ukjDfErwrrteew3yRT1wQ', 'incoming')"
17-05-26 18:47:39.363 [INFO] [acdcli.utils.threading] - 1 jobs in queue.
17-05-26 18:47:39.365 [INFO] [acd_cli] - Uploading /1gbfile.mkv
17-05-26 18:47:39.366 [INFO] [acdcli.api.backoff_req] - POST "https://content-eu.drive.amazonaws.com/cdproxy/nodes"
17-05-26 18:48:27.243 [ERROR] [acd_cli] - Uploading "1gbfile.mkv" failed. RequestError: 400, {"message":"Cannot read from request."}.
[                         ]   0.0% of    1GiB  0/1 -356.6MB/s       0s
1 file(s) failed.

I installed clouddrive to try to upload, and got same errors:

[root@server ~]# clouddrive upload /file8GB.mkv /incoming/
Failed to upload file 'file8GB.mkv': HTTPError: Response code 400 (Bad Request). Reauthenticating and retrying.
Failed to overwrite file: HTTPError: Response code 400 (Bad Request)
Failed to upload file 'file8GB.mkv': Failed retry attempt(s). Skipping file.
sezuan commented 7 years ago

Similar issue here. I'm uploading rather large files (1.5GB - 2.5GB), the upload fails quite often.

AmnaujPr commented 7 years ago

Same problem here, more than 12 hours trying to upload the same files, acd_cli just upgraded

17-05-26 13:26:21.997 [ERROR] [acd_cli] - Uploading "jq64CZDntMTIc29Hft8c5N2u1S8SGJDnyn9HzN,EN4EgLNwKGmicr,EJP2kQ2" failed. RequestError: 400, {"message":"Cannot read from request."}. 17-05-26 13:31:55.087 [ERROR] [acd_cli] - Uploading "N8CmZ4f5NBHwy9hj-,dMinj,IBwNmOG-ftKCA4qe6SqvvD" failed. RequestError: 400, {"message":"Cannot complete upload"}.

pink-mist commented 7 years ago

I've had no problems uploading several multi-GB files

[#########################] 100.0% of    9GiB  1/1     0.0B/s       0s
[#########################] 100.0% of    8GiB  1/1     0.0B/s       0s
[#########################] 100.0% of    2GiB  1/1     0.0B/s       0s

Occasionally I get an error such as

17-05-26 16:54:51.211 [ERROR] [acd_cli] - Uploading "<redacted>" failed. RequestError: 400, {"message":"Cannot complete upload"}.
[                         ]   0.0% of    8GiB  0/1   -3.0GB/s       0s

but that's not a problem with acd_cli, it's a problem with the network link between me and amazon, or possibly simply a problem on amazon's side. Please stop abusing the acd_cli issue tracker for this.

Tangoes commented 7 years ago

Ok @pink-mist, maybe @sezuan @AmnaujPr and me are wrong. Thanks for your help.

zucatti commented 7 years ago

same here. Uploading rather large files (8 GB for instance) result in "Cannot complete upload". This is kind of new problem... I have uploaded terabytes of data without any problem in the past (except that I've got several "rejected" or "timeout" but with with retries switch it worked fine). Revert to commit a5e798fe7c10ddaa24218b9abd5bbbc32902d91d and it's the same problem. So I think the problem is Amazon related!

Tangoes commented 7 years ago

Yes @zucatti I tried with 2 different accounts, and with other software "clouddrive" and got same errors. I will atach this info to the main Post. Thanks for your post.

Tangoes commented 7 years ago

@sezuan @AmnaujPr @zucatti Are you using EUROPE amazon server? (like me) Thats affirmative if you use amazon .uk .es .de...

or just

cat ~/.cache/acd_cli/endpoint_data

will tell you the endpoint location:

{
    "contentUrl": "https://content-**eu.drive**.amazonaws.com/cdproxy/",
    "customerExists": true,
    "exp_time": 14960435.714283,
    "metadataUrl": "https://cdws.**eu-west**-1.amazonaws.com/drive/v1/"
}
pink-mist commented 7 years ago

You may have figured it out if so - I'm on a north-american server, which is working fine.

zucatti commented 7 years ago

I'm on european server unforrtunately cause I think the problem is located on amazon eu

AmnaujPr commented 7 years ago

cdws.eu-west-1.amazonaws also, the problem seems to be here.

maxsternitzke commented 7 years ago

I'm also using Amazon's eu-west server and the support just answered me, there's obviously a problem on multiple servers, so no failures on acd_cli's side and they are working on this issue.

Tangoes commented 7 years ago

Thanks @maxsternitzke for tour update.

AmnaujPr commented 7 years ago

Just uploaded all my files without errors, in the eu servers