Hi Pierre,

On 26.02.2014 00:37, Pierre Malard wrote:

[...]
One limitation has been that you need more memory than the largest file you sync, so if you sync a 4 gb file, you will need 4gb ram as it all gets loaded into there. This may have been solved with chunked uploads a while back, could someone confirm/deny?

Wow!
I don't think we have lot of these file. But I don't know how to test that... However, the "free -h" showed before were take without any activity. My "owncloud.log" is flat at this time...



As mentioned before you do NOT need a PHP memory_limit as high as the biggest file. We're fine with 512MB memory_limit and allow files with up to 20GB (yes GigaByte) in size. Check your "upload_tmp_dir" path in php.ini. This should point to a big enough partition. As also mentioned before all uploaded files are stored there until fully uploaded. If you have many active concurrent users uploading big files, the default /tmp or /var/tmp might be to small.

What about the memory consumption at all?

As I observed, PHP tends to never free memory once allocated. So if your PHP process has allocated the allowed maximum of memory it keeps allocated until the PHP process is recycled. Even if the process is not serving any requests. If you use FCGID, you might limit the number, livetime and "spare" processes to avoid having a high number of PHP processes with max memory usage. If you use mod_php you might tweak the corresponding prefork settings in apache webserver.

If you are running the MySQL on the same server, this one might use a lot of memory for the innodb_buffer_poolsize. You want to have as many data in buffer pool as possible, to reduce IO for the mysql server, but you must left enough memory for the system and the webserver. Check that there is enough RAM in case of maximum usage for the webserver and the mysql server. It is not helpfull if both are configured to use 100% of your RAM.

[...]
but, elsewere, if 5 users needs 1,5 Gb RAM, what about needed RAM for 50?
[...]


Both, php processes and mysql server, does not necessarily need linear more RAM when serving more user. In a normal usage scenario a user does not permanently updates thousands of files and processes are often idle waiting for connections. The apache, php and mysql processes using 1.8GB of RAM might serve 5 users as well as 50users. The scenario where all of your 50 user initially sync their files at the same time, might be a problem, but should be rather rare.


Best regards
Roland Hager

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

_______________________________________________
User mailing list
[email protected]
http://mailman.owncloud.org/mailman/listinfo/user

Reply via email to