Probably one for @cPanelMichael - I'm finding PHP-FPM stalling, and on checking /opt/cpanel/ea-php71/root/usr/var/log/php-fpm/error.log I'm seeing "ERROR: failed to prepare the stderr pipe: Too many open files (24)"
Using the {user} as which php-fpm is specifically running, I'm seeing the following:
Within /etc/security/limits.conf I've got...
And within /etc/security/limits.d/90-nproc.conf I've got...
And running lsof | wc -l for the user in question returns:
In /opt/cpanel/ea-php71/root/etc/php-fpm.d/{user}.conf I've got...
Any ideas/suggestions on how I can diagnose this further? I'm not seeing any mention of hitting max_children in logs or anything else to indicate issues, just this Too Many Files (24) error... previous posts I've looked at for same error have referred to poss fixes for CentOS7, but not found any referring to CentOS6...
CentOS6.10 / WHMv82.0.16
Apache2.4.41 / PHP7.1 / PHP-FPM / MPM: Worker
Using the {user} as which php-fpm is specifically running, I'm seeing the following:
Code:
# ulimit -aSH
core file size (blocks, -c) 0
data seg size (kbytes, -d) 200000
scheduling priority (-e) unlimited
file size (blocks, -f) unlimited
pending signals (-i) unlimited
max locked memory (kbytes, -l) unlimited
max memory size (kbytes, -m) 200000
open files (-n) 5000
pipe size (512 bytes, -p) 8
POSIX message queues (bytes, -q) unlimited
real-time priority (-r) unlimited
stack size (kbytes, -s) 8192
cpu time (seconds, -t) unlimited
max user processes (-u) 384
virtual memory (kbytes, -v) unlimited
file locks (-x) unlimited
Code:
{user} hard nofile 500000
{user} soft nofile 500000
Code:
{user} soft nproc 384
{user} soft nofile 5000
Code:
870
Code:
[{user}]
catch_workers_output = yes
chdir = /home/{user}
group = "{user}"
listen = /opt/cpanel/ea-php71/root/usr/var/run/php-fpm/1733bd16bede7c482577faa383082e8365142cd2.sock
listen.group = "nobody"
listen.mode = 0660
listen.owner = "{user}"
php_admin_flag[allow_url_fopen] = on
php_admin_flag[log_errors] = on
php_admin_value[disable_functions] = exec,passthru,shell_exec,system
php_admin_value[doc_root] = "/home/{user}/public_html/"
php_admin_value[error_log] = /home/{user}/logs/{user}.php.error.log
php_admin_value[max_input_vars] = 4000
php_admin_value[short_open_tag] = on
php_value[error_reporting] = E_ALL & ~E_NOTICE
;php_value[error_reporting] = E_ALL
ping.path = /ping
pm = ondemand
pm.max_children = 200
pm.max_requests = 300
pm.max_spare_servers = 5
pm.min_spare_servers = 1
pm.process_idle_timeout = 20
pm.start_servers = 10
pm.status_path = /status
security.limit_extensions = .phtml .php .php3 .php4 .php5 .php6 .php7
user = "{user}"
CentOS6.10 / WHMv82.0.16
Apache2.4.41 / PHP7.1 / PHP-FPM / MPM: Worker
Last edited: