mysql数据库引擎调优
---------------myisam----------------
• Optimizing disk storage
• Tuning your tables for performance
ANALYZE TABLE, OPTIMIZE TABLE,REPAIR TABLE。
• Using the MyISAM utilities
myisam_ftdump 分析全文索引。
myisamchk 表性能分析。
myisamlog 日志变化分析。.
myisampack 压缩表。
www.2cto.com
• Storing a table in index order
• Compressing tables
• Defragmenting tables
• Monitoring the key cache
• Preloading key caches
• Using multiple key caches
• Other parameters to consider
--------------------innodb---------------
• Using the SHOW ENGINE command
• Using InnoDB monitors
• Monitoring logfiles
• Monitoring the buffer pool
• Monitoring tablespaces
• Using INFORMATION_SCHEMA tables
www.2cto.com
• Other parameters to consider:
innodb_thread_concurrency 调整并发线程0-->独立硬盘分区+cpu内核数;
innodb_fast_shutdown 减少关机时间;
innodb_lock_wait_timeout 默认锁超时;
批量导入数据时候: AUTOCOMMIT;暂时停止外键和唯一值限制。
作者 桔子