I'm looking at running many (dozens, possible hundreds) of small, low-traffic WP installs on one Cloudron. One thing I noticed with my ~three WP installs is that they tend to be RAM hungry. Does Cloudron have any tricks to keeping RAM size reasonable with many sites (as I assume WP multisite hosts do), or is this not a good idea?
@ianhyzy I have about 15-20 WordPress sites running on one server and it’s been fine. Most of them are low traffic sites though, to be fair. I use the PHP.ini fine to tweak some PHP-related settings including memory allotments, and then of course have Cloudron set a max memory allocation to ensure it doesn’t impact other running apps on the server.
@d19dotca thanks! mind sharing any of your php tweaks? I'm curious what other people are doing here
Certainly! The values change periodically for me based on various circumstances, however here's the current values I'm using in the php.ini file for WordPress...
default_socket_timeout = 300 max_execution_time = 300 max_input_time = 60 max_input_vars = 3000 memory_limit = 256M post_max_size = 128M upload_max_filesize = 128M
The top are the values needed usually for best performance from certain page builders and important plugins in WordPress, plus I have a few sites that host videos / other large files so I keep the sizes somewhat large too and tweak as needed for each customer website.
Also, on the wp-config.php file, I also set the following property which allows the WordPress memory limit to match that of the php.ini file, rather than keeping them separate. But in some cases it may be wise to keep them separate too, it's really a case-by-case basis, I just find I often keep them the same so doing it this way means I only have to set it in one spot and removes the risk of keeping them separate unintentionally...
define( 'WP_MEMORY_LIMIT', ini_get( 'memory_limit' ) ); // sets memory limit to match php.ini
Then for the actual application itself, I currently set a 1 GB memory limit on each one.