I have a WordPress site running on my VPS which is quite high-specced (3520MB RAM, 4 Cores). The server runs Nginx and php5-fpm.
Although the site is responsive on the front end, the backend tends to be pretty slow with some admin pages taking several seconds to load. The site runs WooCommerce but I have WP Total Cache running as well as APC object cache.
My question is really about php5-php config as I think I may not have set it up optimally to make use of the server's resources. Here is my
www.conf in php5 pool:
pm.max_children = 10 ; The number of child processes created on startup. ; Note: Used only when pm is set to 'dynamic' ; Default Value: min_spare_servers + (max_spare_servers - min_spare_servers) / 2 pm.start_servers = 2 ; The desired minimum number of idle server processes. ; Note: Used only when pm is set to 'dynamic' ; Note: Mandatory when pm is set to 'dynamic' pm.min_spare_servers = 1 ; The desired maximum number of idle server processes. ; Note: Used only when pm is set to 'dynamic' ; Note: Mandatory when pm is set to 'dynamic' pm.max_spare_servers = 3 ; The number of seconds after which an idle process will be killed. ; Note: Used only when pm is set to 'ondemand' ; Default Value: 10s ;pm.process_idle_timeout = 10s; ; The number of requests each child process should execute before respawning. ; This can be useful to work around memory leaks in 3rd party libraries. For ; endless request processing specify '0'. Equivalent to PHP_FCGI_MAX_REQUESTS. ; Default Value: 0 ;pm.max_requests = 500
I also have
define('WP_MEMORY_LIMIT', '196M'); in wp-config.
Are there any obvious steps I can take to improve the speed of the admin area?
Examining the log I see quite a few of these:
[01-Oct-2014 20:56:38] WARNING: [pool www] seems busy (you may need to increase pm.start_servers, or pm.min/max_spare_servers), spawning 16 children, there are 0 idle, and 7 total children
Anything I can do to solve?
top command when loading an admin page. Are these values reasonable?:
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 23237 www-data 20 0 381m 45m 31m S 10.3 1.4 0:03.52 php5-fpm 23229 www-data 20 0 385m 76m 60m S 5.0 2.3 0:09.54 php5-fpm 23230 www-data 20 0 613m 58m 39m S 4.7 1.7 0:06.38 php5-fpm 1425 www-data 20 0 121m 7000 2292 S 1.3 0.2 87:43.85 nginx