[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Fine tuning MySQL for better performance with Java Application

Posted on 2008-09-30
6
Medium Priority
?
296 Views
Last Modified: 2010-05-18
Hi
previously i asked a question regarding having some issues with connections and have got some fairly reasonable answers

Yesterday i have seen these links regarding 'php' website connected to MySQL and optimising it so as to get better performance...the links for reference are
http://www-css.fnal.gov/dsg/external/freeware/mysqlTuning.html
http://www.getafreelancer.com/projects/sumitp83_302783.html

My application is a Java application and use the MySql and i wish if someone can help regarding similar topics like fine tuning MySQL to work perfectly(or somewhat better) using Java,Tomcat.
you can advice me on persistency,pooling,connection problems,stability,robustness ,faster processing tips etc...

Please provide some solid answers and as some the answers are too vague to actual implement and still requires me to do the homework.thanks
0
Comment
Question by:darien_software
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
6 Comments
 
LVL 25

Expert Comment

by:Tomas Helgi Johannsson
ID: 22612400
      Hi!

I suggest you take a look at the Optimization part of the Manual
http://dev.mysql.com/doc/refman/5.0/en/optimization.html

there you can find all the necessary information to tune your MySQL db to your app.

Regards,
   Tomas Helgi
0
 
LVL 25

Expert Comment

by:Tomas Helgi Johannsson
ID: 22612423
Also what you can do is do an EXPLAIN on your queries ( http://dev.mysql.com/doc/refman/5.0/en/explain.html )
or the log ( http://dev.mysql.com/doc/refman/5.0/en/mysql-explain-log.html ).
If you find in the results that queries are doing TABLESCAN then you should add an index on the
matching columns in the query's where clause to change it into INDEXSCAN for optimal performance on the table.

Regards,
   Tomas Helgi
0
 

Author Comment

by:darien_software
ID: 22624703
hi  tomas
thanks for the details i will look into the material u provided
well i want some details like
what are the parameters have to be changed,a prose sort of to identify the factors which help in fine tuning mysql.
so that then it will be useful to get in details as mentioned in ur link
so if anybody else has any answers please let me know
thanks
0
 
LVL 25

Accepted Solution

by:
Tomas Helgi Johannsson earned 1000 total points
ID: 22624964

How to tune a database depends on how the application works i.e connects to
and manipulate the data in the db.
You have to look into the queries and see how they access the data and
configure the bufferpools, create neccesary indexes etc.
Ask your self:
How are the tables organized?
How are the relationship between the tables ?
Do you use MYISAM or InnoDB ?
Do you have massive inserts (batch), updates or deletes ?
Tuning the database to maximize the performance depends on how you
answer those questions as well as other questions related to disk and locking issues.


Regards,
   Tomas Helig

0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This post looks at MongoDB and MySQL, and covers high-level MongoDB strengths, weaknesses, features, and uses from the perspective of an SQL user.
By, Vadim Tkachenko. In this article we’ll look at ClickHouse on its one year anniversary.
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
Suggested Courses

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question