June 18, 2013

Post: When Does InnoDB Update Table Statistics? (And When It Can Bite)

… a table‘s statistics or index cardinality becomes outdated, you might see queries which previously performed well suddenly show up on slow query… Tmp_tables: 1 Tmp_disk_tables: 0 Tmp_table_sizes: 0 SET timestamp=1316767697; show table status from `db1`; As you can see db1 has about 294 tables

Post: Identifying the load with the help of pt-query-digest and Percona Server

… memory consuming, so ideally you would want to download the “slow query log” to another machine and run it there. Analyzing… # # 100ms # 1s # 10s+ # Tables # SHOW TABLE STATUS FROM `wp_blog_one ` LIKE ‘wp_terms’\G # SHOW CREATE TABLE `wp_blog_one `.`wp_terms`\G # SHOW TABLE STATUS FROM `wp_blog_one…

Post: SHOW INNODB STATUS walk through

… through SHOW INNODB STATUS output, showing what you can learn from SHOW INNODB STATUS …. OS Waits are relatively slow, and if you get …TABLES was used. In addition to Innodb specific information, there is generic statement information which is visible in SHOW PROCESSLIST showed in SHOW INNODB STATUS

Post: Gathering queries from a server with Maatkit and tcpdump

… This lets us gather queries from servers that don’t have a slow query log enabled, at …# 100ms ################################################################ # 1s # 10s+ # Tables # SHOW TABLE STATUS LIKE ‘dual’\G # SHOW CREATE TABLE `dual`\G # EXPLAIN select 1 from ( select sleep(.1) from dual ) …

Post: ALTER TABLE: Creating Index by Sort and Buffer Pool Size

… 10mil row table which would look as following in terms of data and index size: mysql> show table status like “… inserting data in random order can become very slow when index does not fit to memory any …clearly seen from the graphs but with index built by sort enabled the performance of ALTER TABLE

Post: Improved InnoDB fast index creation

TABLE By temporarily dropping secondary indexes from the new table before copying the data, and then recreating them later, ALTER TABLESHOW TABLE STATUS versus 265 MB index size with the optimization disabled. OPTIMIZE TABLE OPTIMIZE TABLE is mapped to ALTER TABLE … ENGINE=InnoDB for InnoDB tables

Post: The MySQL optimizer, the OS cache, and sequential versus random I/O

…’s take a look at the tables. mysql> show table status like ‘fact’\G *************************** 1. row *************************** … the dimension tables doesn’t slow the query perceptibly, because these tables are … the fact table. The LRU policy evicts old blocks from the fact table instead, which …

Post: Visualization tools for pt-query-digest tables

…a tool for visualizing collected data from the MySQL Slow Query Log. The name comes from the instrument in a …show; * filtering queries by hosts; * filtering reports by different query conditions; * graphing reports; * explaining queries; * searching and displaying samples; * displaying table status

Post: How Percona does a MySQL Performance Audit

…, future performance, scalability, ability to recover from disasters? We also want to know …status values for Created_tmp_tables and Created_disk_tmp_tables, I’ll paste in mysql> show global variables like ‘%table….com/scripts/mysqlsla perl mysqlsla -lt slow /path/to/slow.log By default, this outputs …