Recover Table Structure From InnoDB Dictionary

When a table gets dropped, MySQL removes the respective .frm file. This post explains how to recover the table structure if the table was dropped. You need the table structure to recover a dropped table from the InnoDB tablespace. The B+tree structure of the InnoDB index doesn’t contain any information about field types. MySQL needs… Continue reading Recover Table Structure From InnoDB Dictionary

Show Differences Found by pt-table-checksum

First of all, pt-table-checksum is perfect for checking if the master and its slaves are in-sync. It answers the question “Are the slaves consistent with the master?”. However, if they’re not, pt-table-checksum doesn’t actually tell you what exactly is wrong. master# pt-table-checksum -q TS ERRORS DIFFS ROWS CHUNKS SKIPPED TIME TABLE 09-03T22:21:10 0 1 2 1 0… Continue reading Show Differences Found by pt-table-checksum

Published
Categorized as MySQL

Efficient Use Of Indexes In MySQL

These are the slides of the “Efficient Use Of Indexes In MySQL” talk we delivered on the SFMySQL Meetup. This is an introductory talk for developers on MySQL indexes. In my opinion, it’s quite important to understand how InnoDB organizes data. If you know how MySQL accesses data, it’s easier to write optimal queries. When working… Continue reading Efficient Use Of Indexes In MySQL

InnoDB Dictionary

Why Does InnoDB Need A Dictionary An InnoDB dictionary is a set of internal tables InnoDB uses to maintain various information about user tables. It serves as API between a human and the database. While the humans refer to tables by their names, InnoDB works with integer identifiers. The dictionary stores correspondence between table name… Continue reading InnoDB Dictionary