masterross

Well-Known Member
Apr 7, 2004
49
3
158
Hi,

It looks like mysql (10.1.37-MariaDB, WHM v76.0.18) doesnt accept max_open_files set in my.cnf
I have:
table_open_cache = 8000

but after restart when I check var:

MariaDB [(none)]> show global variables like 'table_open_cache';

+------------------+-------+
| Variable_name | Value |
+------------------+-------+
| table_open_cache | 5325 |
+------------------+-------+
1 row in set (0.01 sec)

Also open_files_limit cannot be changed too!
I have set Allow cPanel & WHM to determine the best value for your MySQL open_files_limit configuration? to NO
But this not helping.

Any solution?

EDIT:
I found that if I need to change:
/etc/systemd/system/mariadb.service.d/migrated-from-my.cnf-settings.conf
LimitNOFILE

and then
# systemctl daemon-reload
# systemctl restart mysql

i set LimitNOFILE=16000
And the table_open_cache also changed itself to 7825 automatically.

It's strange but it do the job.
 
Last edited: