Mysql – Confused over table_open_cache

cachemyisamMySQLtuning

I've been reading about the table_open_cache and I'm slightly confused about how big it should be, I've seen conflicting advice. My DB is running on MyISAM and has 199 tables.

I ran into an issue months ago whereby the server was running out of file descriptors, so I've increased the number of file descriptors to 2500 (from default), and the table_open_cache to 1000, and max connections to 500 (probably too high).

I've read this article on negative scalability (https://www.percona.com/blog/2009/11/16/table_cache-negative-scalability/) and now I'm wondering if by increasing these values, performance has been impacted.

I've also ran MySQLTuner and my table cache hit rate is 0%, it shows 1K tables open vs 1M opened. I'm also only using 47% of available the available file limit.

Could anyone point me in the right direction?

Best Answer

Yes, increase table_open_cache.

Are you using Windows? Or *nix? (You are in an area where the OS matters.)

Keep in mind that each MyISAM table involves 3 files.

What is Max_used_connections? That should give you a clue of what max_connections can be lowered to.