nginx+php-fpm change to ondemand mode
-
- Posts: 13
- Joined: Sat Feb 13, 2016 11:03 am
nginx+php-fpm change to ondemand mode
Dear Everyone
i was previously using kloxo-mr and all the while using php-fpm onemand instead of dynamic mode to save some ram
however, i notice there are several php.fpm.conf in vestacp, which is the one i should edit to apply ondemand to all domain and user?
i found them at /usr/local/vestacp/conf/fpm.d/php-fpm.conf and defatut.conf and /etc/php-fpm/php-fpm.conf.d/*.conf
appreciate if any help provided
i was previously using kloxo-mr and all the while using php-fpm onemand instead of dynamic mode to save some ram
however, i notice there are several php.fpm.conf in vestacp, which is the one i should edit to apply ondemand to all domain and user?
i found them at /usr/local/vestacp/conf/fpm.d/php-fpm.conf and defatut.conf and /etc/php-fpm/php-fpm.conf.d/*.conf
appreciate if any help provided
Re: nginx+php-fpm change to ondemand mode
For existing servers or domains edit all files in the pool.d directory including www
/etc/php5/fpm/pool.d/domain.tld.conf
also add this: pm.process_idle_timeout = 10s
- Then restart php5-fpm and nginx servers.
to have this as a default for new domains, edit these 2 files
1- /usr/local/vesta/data/templates/web/php-fpm/default.tpl
2- /usr/local/vesta/data/templates/web/php-fpm/socket.tpl
don't forget pm.process_idle_timeout = 10s
Restart php-fpm and nginx
/etc/php5/fpm/pool.d/domain.tld.conf
also add this: pm.process_idle_timeout = 10s
- Then restart php5-fpm and nginx servers.
to have this as a default for new domains, edit these 2 files
1- /usr/local/vesta/data/templates/web/php-fpm/default.tpl
2- /usr/local/vesta/data/templates/web/php-fpm/socket.tpl
don't forget pm.process_idle_timeout = 10s
Restart php-fpm and nginx