文档介绍:<Insert Picture Here>
MySQL Cluster –
Performance Tuning
Johan Andersson
Principal Field Technologist
The presentation is intended to outline our general
product direction. It is intended for information
purposes only, and may not be incorporated into any
contract. It is not mitment to deliver any
material, code, or functionality, and should not be
relied upon in making purchasing decisions.
The development, release, and timing of any
features or functionality described for Oracle’s
products remains at the sole discretion of Oracle.
General Design Principles
• MySQL Cluster is designed for
• Short transactions
• Many parallel transactions
• Utilize Simple access patterns to fetch data
• Solution that scales!
• Analyze what your most typical use cases are
• optimize for those
Overall design goal
work roundtrips for your
most important requests!
General Design Principles
• Application spaces where Cluster is being used heavily
• Subscriber databases ()
• Session management
• Online gaming
• Finance
• merce
• As a Shard catalog in web shops
• The key denominator for all these applications are:
• high throughput, low response times, high-availability, and
simple access patterns.
• Reporting is typically performed on a subsystem
• Replicate to a slave (, MYISAM or INNODB database)
Tuning Options
• De-normalization
Schema
Optimization • Optimize data types
• Batching
Query Tuning • Rewrite slow queries
• Index Tuning
Parameter • Use a good Configuration (affects mostly stability)
Tuning • Mainly MySQL server parameters
Network / OS • work (TCP) buffers (not the scope of this presentation)
Tuning • Cluster Interconnects
Hardware • Faster CPU/Disk (not the scope of this presentation)
Tuning
Detecting Problems – PT 101
• Enable the slow query log!
• set global slow_query_log=1;
• set global long_query_time=3; //3 seconds
•