Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Best practice for MySQL assignation memory

Status
Not open for further replies.

nb45

IS-IT--Management
May 19, 2003
94
CO
We have a Linux RH5 with 32GB and 64bit server with MySQL5.5. I need determine the memory assignation for the databases and granted the correct performance of these machine.

Currenlty we are using 26GB for MySQL, 7Gb for Java App and we see some problems of performance. Also do you know how i can pursuit this performance behaviour?
 
The "slow query log" may be of assistance here, but the normal querylog can do wonders as well (in showing what happens).

As a developer, I always have a "colored" log viewer (like multitail or baretail) running to see what the database actions are of my application. This shows directly what can be improved.

You can enable both the querylog and the slow querylog in my.cnf or my.ini. Be aware that especially the querylog uses some resources and a lot of disc space, so rotate it. On production machines leave them disabled unless you need them.

In my experience, performance problems are almost always index-related or application-related and have little to do with memory. But if MySQL needs to cache an intermediate result and does it incorrectly in your opinion, a STRAIGHT_JOIN might help.


+++ Despite being wrong in every important aspect, that is a very good analogy +++
Hex (in Darwin's Watch)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top