If you're serious about performance, the guys over at Percona are the definitive authority on such matters. They charge a premium rate, but they get the job done.
If you are insistent on doing it yourself, firstly you want to look at your slow query log. Enable slow query logging, check out the queries that are running slow, and see if you can optimize them. Majority of the time, slow database performance with MySQL is a result of improper indexing and improper use of caching. Also, look into the query caching and/or caching layers for your application.
Beyond that, optimization largely comes down to hard drive throughput, potentially clustering or setting up replication, and further hardware modifications. I cannot stress this enough - before going into hardware modification, go into query and application optimization if possible.
Give the guys at Percona a call (
http://www.percona.com/), and inquire about the following:
- Analyzing query performance based on slow query log
- What queries can benefit from indexing and by how much
- Are you using the right table engines? If not, what table engine should you use, and what impact might this have on coding (VERY IMPORTANT: Modifying your table engine might require very intricate coding changes if your application relies on certain types of table locking)
- What my.cnf settings are ideal for you given your application and hardware configuration?
- If the application is largely read-based, can MySQL replication help you out? If so, make sure to inquire about data consistency across nodes in real-time if all queries must operate on the must up-to-date data (using replication might result in certain queries returning results based on outdated data if not configured properly. By outdated, we're usually talking seconds, or milliseconds). Keep in mind that MySQL cluster and MySQL replication are NOT the same thing. MySQL cluster uses a table engine called NDB, which does not support all the features of MyISAM and InnoDB such as foreign keys.
Also, liquidweb.com has some very fast ssd based servers. Try benchmarking your server on application on a smart ssd server with a raid configuration from liquidweb - chances are you will see a performance boost. Also, most enterprise-level hosting providers offer support regarding MySQL optimization.
Disclaimer: I do NOT work for liquidweb or Percona.