I am having trouble setting the open files limit for user www-data and process PHP in Ubuntu 16.04.
I have set all the following to 65535:
- /proc/sys/fs/file-max
- /etc/sysctl.conf
- /etc/security/limits.conf (both with asterisk (*) and explicitly with user www-data)
- /etc/php/7.0/fpm/php-fpm.conf (and it works for PHP-FPM!)
Still, wenn I grab a php cli process from user www-data, and check via /proc//limits, it shows:
Limit Soft Limit Hard Limit Units Max open files 4096 4096 files
I have searched php.ini which doesn't have a similar setting as php-fpm.conf, so I just copied the one of php-fpm, to no avail as well.
Any ideas?