Larger Uploads Failing (20GB>)

Support intro

Sorry to hear you’re facing problems. :slightly_frowning_face:

The community help forum (help.nextcloud.com) is for home and non-enterprise users. Support is provided by other community members on a best effort / “as available” basis. All of those responding are volunteering their time to help you.

If you’re using Nextcloud in a business/critical setting, paid and SLA-based support services can be accessed via portal.nextcloud.com where Nextcloud engineers can help ensure your business keeps running smoothly.

Getting help

In order to help you as efficiently (and quickly!) as possible, please fill in as much of the below requested information as you can.

Before clicking submit: Please check if your query is already addressed via the following resources:

(Utilizing these existing resources is typically faster. It also helps reduce the load on our generous volunteers while elevating the signal to noise ratio of the forums otherwise arising from the same queries being posted repeatedly).

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can. :heart:

The Basics

  • Nextcloud Server version (e.g., 29.x.x):
    • 31.0.4
  • Operating system and version (e.g., Ubuntu 24.04):
    • Ubuntu 24.04.2
  • Web server and version (e.g, Apache 2.4.25):
    • Apache 2.4.58
  • Reverse proxy and version _(e.g. nginx 1.27.2)
    • External
  • PHP version (e.g, 8.3):
    • 8.2
  • Is this the first time you’ve seen this error? (Yes / No):
    • Yes
  • When did this problem seem to first start?
    • A week ago
  • Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
    • Bare Metal
  • Are you using CloudfIare, mod_security, or similar? (Yes / No)
    • Yes

Summary of the issue you are facing:

When uploading files upward of 20GB there will be an issue where it will completly the upload but when it comes to assembling the chunks of the file it will fail. I have tried with and without my cloudflare proxy and its still the same issue. After looking through the logs it seems to install all the chunks correctly then it will seemingly start to delete them all again. Not sure why this is happening. I have tried completly reinstalling nextcloud. There logs suggest that it seems to not be able to find the uploaded chunks and that is what sets off the chain of deleting the rest. I have checked the permissions of my nfs mount along with any config files on the system.

Steps to replicate it (hint: details matter!):

  1. Install Nextcloud
  2. Create NFS mount and set that to data directory
  3. Start up nextcloud and create account
  4. Change tmp folder to be inside the NFS mount rather than the root directory due to storage limitations
  5. Attempt to upload any large files over 20GB

Log entries

Nextcloud

Please provide the log entries from your Nextcloud log that are generated during the time of problem (via the Copy raw option from Administration settings->Logging screen or from your nextcloud.log located in your data directory). Feel free to use a pastebin/gist service if necessary.

Due to there being little to no useful logs after the error I was getting during upload I changed to log level to 0 to try and get a better idea of what was going on. I have attached below any logs that could be of interest and that occured a the same time as the error. Only two of them being classed as Errors.

![image|344x237](upload://5SJTl5PoA3xGuSZRKw8tek41JWW.png)
![image|690x214](upload://fZ4HYY1fPbpaPGPPGYuvQR1AbVT.png)
![image|690x157](upload://ua7NKzKyTWAlxGlgRIh1V0ZYFxi.png)
![image|690x78](upload://qNSAvS0IuCe0gEE5nEWWLeEm8k0.png)
![image|690x77](upload://tkxEYQRI2EFMN4J4OlStiUqbezb.png)
![image|690x118](upload://4mOeF3tS3PQVMZOP8yR37WLUnyP.png)

The logs below are from a previous install so the timings wont be correct buit its the same issue. This shows that it attmpts to move the upload chunks fails then starts deleting them

{"reqId":"uCM47NcwEVx811Aqwpzb","level":0,"time":"2025-04-15T02:22:41+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"PUT","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/265","mess>
{"reqId":"uCM47NcwEVx811Aqwpzb","level":0,"time":"2025-04-15T02:22:41+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"PUT","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/265","mess>
{"reqId":"uCM47NcwEVx811Aqwpzb","level":0,"time":"2025-04-15T02:22:41+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"PUT","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/265","mess>
{"reqId":"gWNirdYp6Ofn80ORK4Mp","level":0,"time":"2025-04-15T02:23:28+00:00","remoteAddr":"192.168.1.133","user":"Hat","app":"dav","method":"GET","url":"/ocs/v2.php/apps/user_status/api/v1/user_status?format=json","message":"No calendar>
{"reqId":"hoj3hiNbMzVWUPCdVRW2","level":0,"time":"2025-04-15T02:23:52+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"GET","url":"/ocs/v2.php/apps/notifications/api/v2/notifications","message":"dirty >
{"reqId":"ZZaY2CHEoeTgA1s7lxTx","level":0,"time":"2025-04-15T02:23:57+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"dav","method":"PUT","url":"/ocs/v2.php/apps/user_status/api/v1/heartbeat?format=json","message":"No calendar ev>
{"reqId":"JdSd6LLakB5n1sX157CV","level":0,"time":"2025-04-15T02:24:21+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"DELETE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f","messa>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"core","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","message":"!!! >
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":0,"time":"2025-04-15T02:24:22+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"NiWi1Iq8HODMkiCQwj4c","level":0,"time":"2025-04-15T02:24:27+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"GET","url":"/index.php/logout?requesttoken=%2FF%2FwS7DuCofsHcUdQm9zi%2BrXvBsM4FpUP>
{"reqId":"NiWi1Iq8HODMkiCQwj4c","level":0,"time":"2025-04-15T02:24:28+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"GET","url":"/index.php/logout?requesttoken=%2FF%2FwS7DuCofsHcUdQm9zi%2BrXvBsM4FpUP>
{"reqId":"ZNJwKtbKDg5zdS4AlDxB","level":0,"time":"2025-04-15T02:24:28+00:00","remoteAddr":"192.168.1.133","user":"Hat","app":"dav","method":"GET","url":"/ocs/v2.php/apps/user_status/api/v1/user_status?format=json","message":"No calendar>
{"reqId":"iqowNbtsjFqQT7zcXyTl","level":0,"time":"2025-04-15T02:24:28+00:00","remoteAddr":"192.168.1.133","user":false,"app":"bruteForce","method":"GET","url":"/index.php/login?clear=1","message":"The loading of lazy AppConfig values ha>
{"reqId":"QYBjBQ4NlDp2HeGLTCrc","level":3,"time":"2025-04-15T02:24:29+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"MOVE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f/.file","m>
{"reqId":"JdSd6LLakB5n1sX157CV","level":0,"time":"2025-04-15T02:24:29+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"DELETE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f","messa>
{"reqId":"JdSd6LLakB5n1sX157CV","level":0,"time":"2025-04-15T02:24:29+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"DELETE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f","messa>
{"reqId":"JdSd6LLakB5n1sX157CV","level":0,"time":"2025-04-15T02:24:29+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"DELETE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f","messa>
{"reqId":"JdSd6LLakB5n1sX157CV","level":0,"time":"2025-04-15T02:24:29+00:00","remoteAddr":"192.168.1.133","user":"OT","app":"no app in context","method":"DELETE","url":"/remote.php/dav/uploads/OT/web-file-upload-54bd50955c84819f","messa>

Web Browser

If the problem is related to the Web interface, open your browser inspector Console and Network tabs while refreshing (reloading) and reproducing the problem. Provide any relevant output/errors here that appear.

No Problem with web interface

Web server / Reverse Proxy

The output of your Apache/nginx/system log in /var/log/____:

No logs avalable

Configuration

Nextcloud

The output of occ config:list system or similar is best, but, if not possible, the contents of your config.php file from /path/to/nextcloud is fine (make sure to remove any identifiable information!):

{
    "system": {
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "overwriteprotocol": "https",
        "file_upload_buffering": false,
        "trusted_domains": [
            "192.168.1.248",
            "files.REDACTED.com",
            "localhost",
            "192.168.1.177",
            "192.168.1.133"
        ],
        "trusted_proxies": "***REMOVED SENSITIVE VALUE***",
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "tempdirectory": "\/mnt\/nextcloud-nfs\/tmp",
        "dbtype": "mysql",
        "version": "31.0.4.1",
        "overwrite.cli.url": "http:\/\/192.168.1.248",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "mysql.utf8mb4": true,
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "session_lifetime": 86400,
        "session_keepalive": true,
        "memcache.local": "\\OC\\Memcache\\Redis",
        "memcache.distributed": "\\OC\\Memcache\\Redis",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "port": 6379,
            "timeout": 0
        },
        "maintenance": false,
        "files_chunking": {
            "max_chunk_size": "104857600"
        },
        "theme": "",
        "loglevel": 0,
        "updater.release.channel": "stable",
        "defaultapp": "files"
    }
}

Apps

Enabled:
  - activity: 4.0.0
  - app_api: 5.0.2
  - bruteforcesettings: 4.0.0
  - calendar: 5.2.1
  - circles: 31.0.0
  - cloud_federation_api: 1.14.0
  - comments: 1.21.0
  - contactsinteraction: 1.12.0
  - dav: 1.33.0
  - federatedfilesharing: 1.21.0
  - federation: 1.21.0
  - files: 2.3.1
  - files_downloadlimit: 4.0.0
  - files_pdfviewer: 4.0.0
  - files_reminders: 1.4.0
  - files_sharing: 1.23.1
  - files_trashbin: 1.21.0
  - files_versions: 1.24.0
  - firstrunwizard: 4.0.0
  - logreader: 4.0.0
  - lookup_server_connector: 1.19.0
  - nextcloud_announcements: 3.0.0
  - notifications: 4.0.0
  - oauth2: 1.19.1
  - ownershiptransfer: 1.1.0
  - password_policy: 3.0.0
  - privacy: 3.0.0
  - profile: 1.0.0
  - provisioning_api: 1.21.0
  - recommendations: 4.0.0
  - related_resources: 2.0.0
  - serverinfo: 3.0.0
  - settings: 1.14.0
  - sharebymail: 1.21.0
  - support: 3.0.0
  - survey_client: 3.0.0
  - systemtags: 1.21.1
  - text: 5.0.0
  - theming: 2.6.1
  - twofactor_backupcodes: 1.20.0
  - updatenotification: 1.21.0
  - user_status: 1.11.0
  - viewer: 4.0.0
  - weather_status: 1.11.0
  - webhook_listeners: 1.2.0
  - workflowengine: 2.13.0
Disabled:
  - admin_audit: 1.21.0
  - dashboard: 7.11.0 (installed 7.11.0)
  - encryption: 2.19.0
  - files_external: 1.23.0
  - photos: 4.0.0-dev.1 (installed 4.0.0-dev.1)
  - suspicious_login: 9.0.1
  - twofactor_nextcloud_notification: 5.0.0
  - twofactor_totp: 13.0.0-dev.0
  - user_ldap: 1.22.0

Tips for increasing the likelihood of a response

  • Use the preformatted text formatting option in the editor for all log entries and configuration output.
  • If screenshots are useful, feel free to include them.
    • If possible, also include key error output in text form so it can be searched for.
  • Try to edit log output only minimally (if at all) so that it can be ran through analyzers / formatters by those trying to help you.

The same is happening to me with a new installation, same version 31.0.4 AIO docker installation on Ubuntu VM

I think it is a timeout issue, after some time, regardless of the file size. I tried with different types of underlying storage, and with my fastest storage the crash during “assembling” is the one producing the biggest file:

  1. slow storage → I can’t upload 6GB, when the assembled file reaches 4GB-4.5GB it crashes. (CephFS - 4 Servers with 10 OSD each, HDD only, no SSD/NVME at all ), When using both files, 6GB and 14GB files it crashes around the same assembling size, 4-4.5GB

  2. average storage → I can upload 6GB, I can’t upload 14GB, when the assembled file reaches around 10GB, it crashes. (4 servers with 12 OSD/HDD each, plus 2x Enterprise SSD for DB/WAL)

PD: My fastest storage is probably slower than yours.

Which version were you using previously that you didn’t see this error?

Forgot to mention, that In all the cases, all the chunks are uploaded properly adding to the total size of the files; but assembling them, is where it crashes.

Can’t this be scheduled in the background with a notification when the files is “assembled” ?

I also tried increasing the chunk size in config.php

'files.chunked_upload.max_size' => 100 * 1024 * 1024,

and setting it to zero

when setting it to zero, the upload crashes around 10GB (same as the assembling crashing size)

sudo docker run \
--init \
--sig-proxy=false \
--name nextcloud-aio-mastercontainer \
--restart always \
--publish 8080:8080 \
--env APACHE_PORT=11000 \
--env APACHE_IP_BINDING=0.0.0.0 \
--env APACHE_ADDITIONAL_NETWORK="" \
--env SKIP_DOMAIN_VALIDATION=true \
--env NEXTCLOUD_DATADIR="/mnt/ncdata" \
--env NEXTCLOUD_UPLOAD_LIMIT=64G \
--env PHP_UPLOAD_LIMIT=64G \
--env POST_MAX_SIZE=64G \
--env MAX_INPUT_TIME=3600 \
--env MAX_EXECUTION_TIME=3600 \
--volume nextcloud_aio_mastercontainer:/mnt/docker-aio-config \
--volume /var/run/docker.sock:/var/run/docker.sock:ro \
ghcr.io/nextcloud-releases/all-in-one:latest

Before installing 31.0.4 AOI in the VM I was doing a 30.0.x Kubernetes helm installation, and I was able to upload 14GB file, however, when I tried to upload a folder 24GB with many files, it failed.

Yeah, I did think it was a timout issue at first aswell. So I adjusted all the possible timeouts I could to see if that would somehow fix the issue.

First I changed my proxy timeouts in Nginx Proxy Manager which for me is running in a seperate VM. The settings that I set were.

client_max_body_size 512G;
proxy_read_timeout 14400;
proxy_connect_timeout 14400;
proxy_send_timeout 14400;
client_body_buffer_size 2M;
proxy_buffer_size 512k;
proxy_buffers 8 512k;
proxy_busy_buffers_size 1024k;

Second I changed my php timeouts in my /etc/php/8.2/fpm/php.ini file.
I changed the following

upload_max_filesize = 512G
post_max_size = 512G
memory_limit = 4G
max_execution_time = 7200
max_input_time = 7200

Then also in my /etc/apache2/apache2.conf config

Timeout 7200
KeepAliveTimeout 7200

I also increased the session timeouts inside /var/www/nextcloud/config/config.php

'session_lifetime' => 86400, 
'session_keepalive' => true,

There is a chance that maybe this might help you. My first thought after trying this was that is was a cloudflare timeout that was triggering as the after setting the log level to 0 I could see that after the attempted MOVE of the chunks it would fail and start deleting the created chunks. This turned out not to be the case as I tried turning off cloudlfares proxy and the issue still occured.

Are you by any chance using an NFS mount as your main data folder as this is what I am going to attempt to diagnose next.

this did the trick for 14GB

In my case I am using HAProxy

  timeout queue           10m
  timeout client          10m
  timeout server          10m

these values were at 1m… and aprox at 1 min of starting assembling that was when the crash was going on.

I will try with a larger file.

Thanks for the tip… !!

No worries!

I am going to keep trying to figure out what could possibly be going on with mine.

I was able to upload a 55GB file

Then, I changed back the HAProxy values only to 1m instead of 10m and got the crash again with 14GB during assembling.

If there is any developer reading this.

Seems to me that while the upload is not an issue because of the chunking and sending packages very often and updating the interface with the progress bar; I can even upload 60GB until the assembling part.

When the assembling message triggers, there is no update in the UI, and then the HAProxy (in my case) timeout triggers something that makes the connection reset/crash and then the nextcloud app deletes the uploaded chunks, making it impossible ton continue assembling.

So… either continue updating the UI while assembling, or execute the assembling process disconnected and in the background; and sending a notification when the assembling is complete.

Although, I remember than when I removed the chunking, I got a crash related to HAProxy timeout (my guess)

I left this

'session_keepalive' => true,

and still while reducing the HAProxy timeout to 1m, the assembling phase crashes; seems that session_keepalive is not working for a proxy?

Thanks again.

Guys,
I have made some testing - check it here.

1 Like

Yeah, so I seemed to have figured out the issue. Its something to do with my data folder being inside my NFS share. The install all runs okay its just something about uploading large files it doesnt seem to like. Has anyone had any success with using NFS as their datafolder and if so how?