Skip to content

Uploads >60s over HTTP/2 are terminated by Traefik due to readTimeout #625

@tom-0221

Description

@tom-0221

Uploads that take longer than 60 seconds and use HTTP/2 are terminated by Traefik due to the default readTimeout of 60 seconds. This issue does not occur when using HTTP/3.

How to reproduce:

  1. Open Firefox and go to about:config
  2. Set network.http.http3.enabled to false to force HTTP/2
  3. Start a file upload via the Nextcloud web interface (Use a tool like NetLimiter to throttle the upload speed so that it lasts longer than 60 seconds)
  4. The upload fails (with a 502 Bad Gateway Timeout)

Root cause:
Traefik’s default readTimeout is set to 60 seconds. Under HTTP/2, if no data is received during that period, Traefik closes the connection—even if the upload is still in progress.

Workaround:
Setting this label on the affected container resolves the issue:

traefik.http.services.nextcloud.loadbalancer.server.readtimeout=120s

Suggestion:
It would be helpful if mash could either:

  • Document this edge case for Nextcloud and similar apps with long-lived uploads
  • Or apply a higher default readTimeout for such cases automatically

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions