June 18, 2013

Post: MySQL Slow query log in the table

MySQL 5.1 get MySQL slow query log logged in mysql.slow_log table instead of the file as you had in… finding how many queries were accumulated in the logs or finding 10 last queries is not fast. The good…, neither you can delete rows from it (or do any write queries) only read access is possible, with…

Post: XtraDB: The Top 10 enhancements

Last week I talked about why you don’t want to shard. This week I’m following up with the top 10 enhancements that XtraDB has over the built-in InnoDB included in MySQLread_threads, innodb_write_threads (see docs). Better Diagnostics – The SHOW ENGINE INNODB STATUS command in

Post: SHOW INNODB STATUS walk through

… things. In MySQL 5 number of Innodb performance counters were exported and now available in SHOW…2: len 7; hex 00000040150110; asc @ ;; 3: len 10; hex 61202020202020202020; asc a ;; *** (2) TRANSACTION: …0.00 reads/s Finally last section – row operations which shows activity on the row basics and …

Post: Enum Fields VS Varchar VS Int + Joined table: What is Faster?

…means to retrieve each row MySQL will have to perform OS system call to read the row, at this …rows: 225690 Extra: 2 rows in set (0.10 sec) Because we refer state by name, which is unique,it is pre-read…. And the last test – selecting city and name in arbitrary order, skipping first 10000 rows to make…

Post: Estimating Replication Capacity

mysql> select * from information_schema.user_statistics where user=”#mysql_system#” \G *************************** 1. row *************************** USER: #mysql…: 0 ROWS_FETCHED: 0 ROWS_UPDATED: 127576 TABLE_ROWS_READ:…0 1 row in set (0.00 sec) In … 0 0 0 # Last errn 34…logs applies for 10 minutes we …

Post: EXPLAIN EXTENDED can tell you all kinds of interesting things

reading const tables | +—-+————-+——-+——+—————+——+———+——+——+—————————————————–+ 1 row in set, 1 warning (0.04 sec) mysqlLast, EXPLAIN EXTENDED can show you information about the query rewrites that MySQL

Post: Find where your data is replicated, win a Percona Live ticket

… Monday, so this is the last in the series of free-Percona-Live… have you ever wondered what servers are in your MySQL replication hierarchy? We have, too. … not read_only Filters replicate_wild_ignore_table=foo%.mount% Binary logging ROW Slave… InnoDB version 1.0.6-unknown +- 10.153.116.5 Version 5.1…

Post: Do you always need index on WHERE column ?

…, but this topic popups again and again. Today I’ve read opinion that if we have clause WHERE has_something=1… row in set (20.27 sec) mysql> select count(name) from testr ignore key (has_something) where has_something=0; 1 row in set (10.62…) mysql> select count(name) from testr ignore key (has_something) where has_something=0; 1 row in set (10.43 sec) So only in the last

Post: Analyzing air traffic performance with InfoBright and MonetDB

In total raw data is about 55GB. Average amount of rows in10) DEFAULT NULL, `Div5LongestGTime` varchar(10) DEFAULT NULL, `Div5WheelsOff` varchar(10) DEFAULT NULL, `Div5TailNum` varchar(10) DEFAULT NULL ) ENGINE=BRIGHTHOUSE DEFAULT CHARSET=latin1; Lastin InfoBright. MySQL

Post: Logging Foreign Key errors

…seconds and will check the last error every 10 seconds. 3- Cause an error…mysql> select * from test.foreign_key_errors\G *************************** 1. row *************************** ts: 2012-09-26 14:28:31 error: Error in… key errors log them. Just reading the last error happened on the databases is…