This issue is really problematic. Because it’s a feature refgression regarding to the specs required for nextcloud.
Nextcloud does not require a 64bit system in the specs and lot of people run this on not 64bits Arm systems like older rapsberry pi or custom openhardware nas with low cpu/ram.
I think that there are 2 aspects in this problematic :
- Create an archive
- Compress this archive
Nowadays lots of people got good internet access so compression is not interesting
Also, in a cloud you store things that are already compressed like Jpeg images or mp3 or MsOffice files
If you store raw text for your next scifi book or code you have better to put it in a gitlab 
So, imho, our question is how to download multiple files and folder in a single way and not about compressiong the files.
I found this article that seems related to the zip function issue: https://stackoverflow.com/questions/5745255/php-aborting-when-creating-large-zip-file
Can we have any workaround to this ? It’s really problematic for the user experience.
What about theses potential solutions :
- Use cli or alternate php function to create the zip archive
- Propose other archive format in the UI (tar, 7zip…)
- Show a warning in webui that takes care of the size of data to be archived
- Update the specs to require 64bit system for nextcloud
EDIT : The workflow can be different and may help to solve the problem. Maybe the archive can be prepared somewhere instead of using a stream ? It must not be a problem because it only uses diskspace instead of cpu
Thanks for your help