Nextcloud 27 on 32-bit PC Downloading large file problems

I used to run Nextcloud 25 on a 32-bit Debian 10 system and never had any real problems downloading large files. Since Nextcloud 26 & 27 doesn’t require 64-bit anymore i updated my 32-bit system to Nextcloud 27.0.1. It works but downloading larger files gives me a headache. Uploading / syncing large files is no problem at all.

Downloading files >3,3 Gb from any browser (Safari / Edge) and client app on iOS simply does not work anymore. It used to work with Nextcloud 25 and PHP 7.4. Now i’m running PHP8.2. I’ve done all necessary tweaks for Apache, PHP and Nextcloud to increase the filesize-limits.

Downloading in browser on desktop with Edge-browser starts and as soon as it reaches the end of the download 99% it just starts over again at 1% so the download never finishes.

Downloading (make offline available) the same big file in the iOS-client app stops at aprox 2 Gb and gives an error 200 Transfer stopped.

I’ve enabled logging in Nextcloud but there is no error to be found. I’ve enabled PHP-logging and no errors were found. Also no errors to be found in Apaches logs either.

Downloading via WebDAV also fails when files are larger.

Placing the same file (.mp4-video) in the root of my webserver and downloading it gives no trouble at all so my Apache webserver is not the culprit. I can choose to download en play directly.

I’m sure that there is something to do about this since it worked on earlier versions of Nextcloud <25 on the same system.

Could somebody please explain why it’s not working anymore? There used to be workarounds for these kind of problems.

Edit: Downloading a large folder 6 Gb works! Nextcloud compresses the folder in the background to a zip-file roughly 4,3 Gb in size and then downloading works. So it’s not 32-bit related at all. Looks like a file-type problem to me.

My system:
Operating System: Linux 4.19.0-24-686-pae i686
CPU: Intel(R) Core™ i3 CPU 550 @ 3.20GHz (4 cores)
Memory: 7.64 GB

Unfortunately, I strongly suspect that if you look closer at the contents of that file it’ll be incomplete/corrupted. First, NC’s zip doesn’t compress (it’s just meant as a convenient way to download multiple files as a bundle). Second, the “limit” on 32-bit is probably 4,294,967,295 (2^32-1) and your download is suspiciously around that boundary. In some cases, the limit might be ~2GB (2^31-1).

My understanding is that you will not necessarily see errors or warnings in all cases. It’s simply undefined (odd or unpredictable) behavior depending on a combination of factors.

While the prior workarounds (from earlier NC versions) were adapted into more recent NC versions[1], there are also differences in how the underlying pieces (i.e. PHP versions and OS libraries) handle things. Also it’s possible there are places where additional workarounds are needed (or existing ones need adjusting), but have been overlooked.

You might get a few more clues if you set logging to level 0 and/or enable debug mode (both only temporarily!), but I doubt it’ll catch everything. If you find something, it may technically be a bug.

Or you could update the OS to 64-bit on the same CPU. ducks

[1] Bring back 32 bit support on Nextcloud 26 · Issue #36072 · nextcloud/server · GitHub

Oh no! you are right. It’s not compressed but packed/bundled. I’ve just tried to download my Photo’s folder roughly 7,9 Gb in size. My browser downloads it as a .zip-file and stops at exactly 4,3 Gb in size (4,298,576,248 bytes).
just missed-------:mans_shoe: . Updating to 64-bit is on my to-do list. Not yet decided to just start over with a fresh new install and restore Nextcloud’s data.