MySqueal like a pig

Submitted by reeses on Tue, 2005-05-24 21:31. | |

http://www.astrogoth.com/~reeses/media/blog/may_orchid.jpg

So, it's abundantly obvious that I don't know how to maintain a minimal MySQL box. I had assumed that once I set up databases and grants, that would be about it for my tiny little universe of websites.

I got an IM that I was showing a "too many connections" on my wiki, and sure enough, PhpWiki was giving every browser a tremendously ungoogle-able error message. (All the hits were to sites with the same problem, not sites discussing the problem.)

Apparently the default mysql table_cache value is set to 64, which is woefully undersized for a max_connections setting of 100 -- that table_cache should be set to some value (n x max_connections) where n = the number of joins expected in the application.

I've added set-variable=table_cache=512 to my /etc/my.cnf, and all appears good at this point.

Post new comment

Captcha Image: you will need to recognize the text in it.
Please type in the letters/numbers that are shown in the image above.