• 9 years

    2 years

    YetiShare / Core


Performance tuning your servers for YetiShare

Your server configuration can have a significant impact on the performance of YetiShare. Below are some of the server settings we'd recommend using. This page will be added to over time so it's not a definitive list. It assumes you have at least a VPS server with root access.


- Enable XSendFile to take load away from PHP -

Nginx (recommended over Apache)

- Enable X-Accel-Redirect to take load away from PHP -
- Additional advice on general Nginx performance tuning here:
- Some Nginx security advice (note: not all tested):

- Amend /etc/nginx/nginx.conf
http { 
    fastcgi_read_timeout 300;
Restart Nginx after any changes.


- Amend the following values in your global php.ini file:

memory_limit = 512M
upload_max_filesize = 500M
post_max_size = 500M
max_execution_time = 180
max_input_time = 180
Restart your webserver to apply the changes.

PHP-FPM (if using Nginx)

- Amend /etc/php5/fpm/pool.d/www.conf

request_terminate_timeout = 300

pm = ondemand
pm.max_children = 75
pm.process_idle_timeout = 10s

 Source for max_children -


- If you're using FastCGI with PHP/Apache ensure you allow for any timeouts on large downloads, by default they will close connections after 5 minutes so you may get partially completed downloads. In your Apache config file add the following:

<IfModule mod_fcgid.c>
FcgidBusyTimeout 43200

If you're using WHM/cPanel you can add this to /usr/local/apache/conf/includes/post_virtualhost_global.conf

Save and restart Apache.


1) Enable query cache.

Edit my.cnf file (sometimes in /etc/mysql/my.cnf)

nano /etc/my.cnf
Add or uncomment the following lines:

query_cache_size = 268435456
query_cache_type = 1
query_cache_limit = 1048576
2) Increase max connections in MySQL. In your my.cnf file, add or amend the following:

max_connections = 600

3) Increase timeouts in MySQL to allow longer for large uploads. In your my.cnf file, add or amend the following:

wait_timeout = 120
interactive_timeout = 120
Restart MySQL. (this command will be different depending on your OS)

service mysql restart
Save and restart MySQL. You may need to adjust this value depending on your traffic levels and server resources available.


  • Use CloudFlare to reduce load, speed up website content to your users and protect against DOS attacks.
  • IMPORTANT - If using CloudFlare, ensure you have the following disabled (on the 'speed' tab), these are known to cause issues:
    • Rocketloader
    • Auto-minify Javascript

Useful Links