Showing posts with label skip-name-resolve. Show all posts
Showing posts with label skip-name-resolve. Show all posts

Sep 15, 2009

MySQL Slow Conncections

One of our clients had a performance issue with slow connections to its MySQL database.
The system configuration is MySQL 5.1 on Red Hat, and the application Java/Tomcat based and ORM is done using iBatis.

Several things can be done to solve this issue (make the open connection in few ms instead of 9 seconds) :
  1. Use skip-name-resolve in my.cnf file in order to avoid DNS queries that slow down the connections (my.cnf example can be found in http://forums.mysql.com/read.php?11,28690). Another work around can be writing the host resolve in the server hosts file.
  2. Use MySQL Connector/j 5.1.17 that makes iBatis run faster twice than 5.1.16.
That's all for now, feel free to add your recommendations

Keep Performing,
Moshe Kaplan. RockeTier. The Performance Experts.

ShareThis

Intense Debate Comments

Ratings and Recommendations