Hi, I'm running woocommerce on my VPS and after restarting the server my CPU can't get back to normal.
htop is saying that it's PHP issue.
I'm trying to balance somehow FPM config but that doesn't work.
This is my config :
[global]
pid = /www/server/php/80/var/run/php-fpm.pid
error_log = /www/server/php/80/var/log/php-fpm.log
log_level = notice
[www]
listen = /tmp/php-cgi-80.sock
listen.backlog = 8192
listen.allowed_clients = 127.0.0.1
listen.owner = www
listen.group = www
listen.mode = 0666
user = www
group = www
pm = dynamic
pm.status_path = /phpfpm_80_status
pm.max_children = 200
pm.start_servers = 20
pm.min_spare_servers = 20
pm.max_spare_servers = 40
request_terminate_timeout = 200
request_slowlog_timeout = 90
slowlog = var/log/slow.log
in the logs I can see this : [17-Aug-2021 09:13:00] WARNING: [pool www] seems busy (you may need to increase pm.start_servers, or pm.min/max_spare_servers), spawning 16 children, there are 14 idle, and 55 total children
Also sometimes I'm getting this error from SQL : [Warning] Aborted connection 986 to to db: xxx, user: xxx host: 'localhost' (Got an error reading communication packets)
My VPS config is
4 x CPU
16GB of RAM
240GB of SSD
Even when there are almost no connections the CPU is going up and down all the time..
Also, I'm using Memcached 1.6.9 + Website Speed 2.9
For the SQL I'm using: MYSQL 10.4.14 - MariaDB
NGNIX - 1.21
PHP version 8.0
plus NGNIX Freee firewall 5.0
Any tips on how to find the root cause? and how to optimize these processes?
Thanks