May 24, 2012

Comment: How to recover a single InnoDB table from a Full Backup

table –target-dir=/mnt/mysql/export/ –tables=data # xtrabackup_55 –prepare –export –innodb-file-per-table –target-dir=/mnt/mysql/export ALTER TABLE…: 9 indexes have been detected. InnoDB: Progress in %: 1 2 3 4 5 6 7… 4:38:52 InnoDB: Error: page 0 log sequence number 6094071743825 InnoDB: is …

Post: Hacking to make ALTER TABLE online for certain changes

ALTER TABLE `huge_table` CHANGE `id` `id` int(6) NOT NULL and then wait hours for table

Post: Thinking about running OPTIMIZE on your Innodb Table ? Stop!

mysql> alter table a drop key c; Query OK, 0 rows affected (0.46 sec) Records: 0 Duplicates: 0 Warnings: 0 mysql> optimize table a; +——–+———-+———-+——————————————————————-+ | Table

Post: How Percona does a MySQL Performance Audit

0 | 0 | | Binlog_cache_use | 9630066 | 468 | | Bytes_received | 38563413074 | 1708212 | | Bytes_sent | 216162991863 | 7796961 | | Com_admin_commands | 255868807 | 11893 | | Com_alter_db | 0 | 0… This is happening 6 times every …mysql.* tables, running mk-duplicate-key-checker to find redundant indexes

Post: Copying InnoDB tables between servers

tables=tpcc.order_line* –target-dir=/data/vadim/mysql/export/ xtrabackup: tables regcomp(): Success xtrabackup Ver 0.8.1rc Rev 78 for 5.0… When it’s done, final import command: alter table order_line import tablespace; now some …: import: 2 indexes are detected. InnoDB: Progress in %: 1 2 3 4 5 6 7 …

Post: Impact of the sort buffer size in MySQL

index are available to help the sorting so I created a MyISAM table with one char column without an index: CREATE TABLE…100000 COUNT=0 while [ "$NUMROW" -gt "$COUNT" ] do UUID=`uuidgen` mysql …the benchmark by doing “alter table sorttest engine=myisam;”. The…GNU/Linux MySQL: 5.1.41-3ubuntu12.6-log P….

Post: SHOW INNODB STATUS walk through

0 42313619, ACTIVE 49 sec, process no 10099, OS thread id 3771312 starting index read mysql tables…be zero. History list length 6 is number of unpurged transactions…tables for normal operation so number of tables locked normally stays 0, unless it is ALTER TABLE or similar statement, or if LOCK TABLES

Comment: MySQL Server Memory Usage

alter_db’, ‘0‘ ‘Com_alter_table‘, ’7′ ‘Com_analyze’, ‘0‘ ‘Com_backup_table‘, ‘0‘ ‘Com_begin’, ‘0‘ ‘Com_change_db’, ’155′ ‘Com_change_master’, ‘0‘ ‘Com_check’, ‘0‘ ‘Com_checksum’, ‘00 0 0 0 0 0 1 0 1 1 0 0 553604 18548 37316 3349456 0 0 1210 143 2476 3809 19 1 70 10 mysql

Post: Tuning InnoDB Concurrency Tickets

…: 0 mysql> ALTER TABLE test_table ADD INDEX (id); — 5 Tickets Used Query OK, 3 rows affected (0.01 sec) Records: 3 Duplicates: 0 Warnings: 0 And …0.00 sec) Records: 3 Duplicates: 0 Warnings: 0 mysql> DELETE FROM child WHERE 1; — 6 Tickets Used Query OK, 3 rows affected (0.02 sec) mysql> ALTER TABLE

Post: Joining on range? Wrong!

… ref: NULL rows: 1306 Extra: Using where; Using index In this case MySQL does not print ref at all, because there is… using it for filtering instead: ALTER TABLE items_ordered ADD itm_order_date DATE NOT NULL, ADD INDEX itm_prd_id__and__itm….g. #8569, #19548). Some replies from MySQL indicate this may be eventually fixed in 6.0 or some future version. Others say “itâ…