Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Long processing times while uploading to S3 #19223

Open
solracsf opened this issue Jan 30, 2020 · 10 comments
Open

Long processing times while uploading to S3 #19223

solracsf opened this issue Jan 30, 2020 · 10 comments
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap 25-feedback bug feature: object storage

Comments

@solracsf
Copy link
Member

solracsf commented Jan 30, 2020

Running Nextcloud 17.0.3 behind Cloudflare works fine, unless the upload processing time takes longer than 100s (in our case, uploading files bigger than 2GB trough WebUI to a S3 primary backend). In that case, Cloudflare returns a 524.

Error when assembling chunks, status code 524

image

Contacting Cloudflare about this hits on a:

... modify your process so it sends a keep alive request...

Cloudflare will typically wait for a HTTP response from origin server for 100 seconds. If no response (or <8Kb) is sent by the origin in that time, Cloudflare will close the connection and serve a 524 error page.

So the question is, can (should?) Nextcloud detect those long running processing times and send a keepalive request every (say) 60 seconds to avoid these problems on some proxies like Cloudflare?

@solracsf solracsf added bug 0. Needs triage Pending check for reproducibility or if it fits our roadmap labels Jan 30, 2020
@solracsf solracsf changed the title Send keepalive tp proxies on long running uploads Send keepalive request to proxies on long processing times Jan 30, 2020
@solracsf solracsf changed the title Send keepalive request to proxies on long processing times Long processing times while uploading to S3 Feb 18, 2020
@FlorentCoppint
Copy link
Contributor

By the way, to complete this issue, sometimes some chunks are "missing" on S3 storage (404 Not found) ! So the assembling step is failing. Maybe there should be some checks when sending chunks to S3, if they are not correctly saved, maybe resend them...

@dwehrmann
Copy link

I can confirm this happens for me too (error 524) without cloudflare – only when uploading files larger than 1GB. Note that the uploading process finishes fine, the error raises on processing (presumably chunks) on the s3 storage.

`Error: fclose(): supplied resource is not a valid stream resource at /var/www/nextcloud/3rdparty/icewind/streams/src/Wrapper.php#96

<<closure>>

OC\Log\ErrorHandler::onError()

/var/www/nextcloud/3rdparty/icewind/streams/src/Wrapper.php - line 96:

fclose()

/var/www/nextcloud/3rdparty/icewind/streams/src/CallbackWrapper.php - line 117:

Icewind\Streams\Wrapper->stream_close()

<<closure>>

Icewind\Streams\CallbackWrapper->stream_close()

/var/www/nextcloud/3rdparty/guzzlehttp/psr7/src/Stream.php - line 108:

fclose()

/var/www/nextcloud/3rdparty/guzzlehttp/psr7/src/Stream.php - line 74:

GuzzleHttp\Psr7\Stream->close()

<<closure>>

GuzzleHttp\Psr7\Stream->__destruct()`

I'm using latest nextcloud version to date.

@Yaya48
Copy link

Yaya48 commented Jun 20, 2021

Is there any news for this issues?

@szaimen
Copy link
Contributor

szaimen commented Aug 8, 2021

Is this Issue still valid in NC21.0.3? If not, please close this issue. Thanks! :)

@Yaya48
Copy link

Yaya48 commented Aug 8, 2021

Is this Issue still valid in NC21.0.3? If not, please close this issue. Thanks! :)

Yeah it's still valid.

@szaimen szaimen added 1. to develop Accepted and waiting to be taken care of and removed needs info 0. Needs triage Pending check for reproducibility or if it fits our roadmap labels Aug 8, 2021
@pierreozoux
Copy link
Member

Closing as a duplicate of #17992.

@szaimen szaimen reopened this Oct 3, 2022
@szaimen
Copy link
Contributor

szaimen commented Jan 9, 2023

Hi, please update to 24.0.8 or better 25.0.2 and report back if it fixes the issue. Thank you!

@szaimen szaimen added needs info 0. Needs triage Pending check for reproducibility or if it fits our roadmap and removed 1. to develop Accepted and waiting to be taken care of labels Jan 9, 2023
@Lixar91
Copy link

Lixar91 commented Jan 25, 2023

Hi, please update to 24.0.8 or better 25.0.2 and report back if it fixes the issue. Thank you!

The problem still exists in Nextcloud 25.0.3 😢

@weasam
Copy link

weasam commented Feb 12, 2023

My Nextcloud snyc windows client also have this issue, in my windows nextcloud logs says 524, which is cloudflare issue, check the server load and response both are ok, what I know is the Sync client sync a large file, it stop for a while at the sync process. so I blame nextcloud sync client, lol. why it stop, keep going

@anguschang007
Copy link

No any solution yet?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap 25-feedback bug feature: object storage
Projects
None yet
Development

No branches or pull requests

9 participants