Presenting Undrop for InnoDB Toolkit on Percona Live 2015

I’ll be presenting Undrop for InnoDB data recovery toolkit on Percona Live 2015. The conference takes place in Santa Clara on 13-16 April. You may wonder why do I care if I plan to drop none of my production databases. To name few reasons: Taxes, death and data loss are inevitable Good knowledge of how […]


Xtrabackup and MySQL 5.6 on Amazon instance

Have you ever tried to install Xtrabackup on Amazon EC2 instance with Oracle’s MySQL 5.6? Dependencies hell strikes when you ask pretty common and reasonable thing – run the GA version of MySQL and backup it with the most popular open-source tool – XtraBackup. From this post you will learn how to resolve the conflicts […]


How to handle wrong page type in external pages

First step of successful MySQL data recovery is to find InnoDB pages with your data. Let’s call it first, because prerequisite steps are already done. InnoDB page type is a two bytes integer stored in the header of a page. For MySQL data recovery two are important: FIL_PAGE_INDEX. Pages of this type are nodes of […]


Presenting TwinDB Data Recovery Toolkit on #SFMySQL Meetup 1

On 5 November, I’ll be speaking at #SFMySQL Meetup about Data Recovery Software for MySQL Add Slipped & DROP’d your TABLE? Recover w/TwinDB’s Undrop for InnoDB toolkit to your calendar. There will be a demo and if you want to try to undrop a table yourself bring in a laptop with Linux. Download the latest […]


Temporary table naming scheme in 5.6 and before 1

Benchmarking is a popular topic. People love drawing graphs as much as watching how X is 10% faster than Y; there must be something special in measurements. For a DBA, however, more tangible improvements come from less popular area of database maintenance. While MariaDB spreads FUD around InnoDB (nonetheless still uses it) I have to […]


Resolving page corruption in compressed InnoDB tables

Sometimes corruption is not the true corruption. Corruption in compressed InnoDB tables may be a false positive. Compressed InnoDB table may hit false checksum verification failure. The bug (http://bugs.mysql.com/bug.php?id=73689) reveals itself in the error log as follows: 2014-10-18 08:26:31 7fb114254700 InnoDB: Compressed page type (17855); stored checksum in field1 0; calculated checksums for field1: crc32 […]


Recover Table Structure From InnoDB Dictionary 3

When a table gets dropped MySQL removes respective .frm file. This post explain how to recover table structure if the table was dropped. You need the table structure to recover a dropped table from InnoDB tablespace. The B+tree structure of InnoDB index doesn’t contain any information about field types. MySQL needs to know that in […]


Take image from corrupted hard drive

There are at least two cases when it makes sense to take an image from a corrupted hard drive as soon as possible: disk hardware errors and corrupted filesystem. Faulty hard drives can give just one chance to read a block, so there is no time for experiments. The similar picture with corrupted filesystems. Obviously something […]


Recover Corrupt MySQL Database

The unDROP for InnoDB tool can be used to recover corrupt MySQL database. In this post we will show how to repair MySQL database if its files became corrupted and even innodb_force_recovery=6 doesn’t help. The corruption of InnoDB tablespace may be caused by many reasons. A dying hard drive can write garbage, thus page checksum […]


Repair Corrupted InnoDB Table with Corruption in Secondary Index

InnoDB provides no means to repair corrupted table space. Once a table got corrupt the only way to repair MySQL files is to start it with innodb_force_recovery={4,5,6} in hope that you can dump the table, so you can rebuild the table space from scratch. At least this is what the manual says. But let’s take […]


Recover after DROP TABLE. Case 2

Introduction In the previous post we described the situation when TwinDB recovery toolkit can be used to recover accidentaly dropped table in the case innodb_file_per_table=OFF setting. In this post we will show how to recover MySQL table or database in case innodb_file_per_table is ON. So, let’s assume that mysql server has setting innodb_file_per_table=ON. This option […]


Recover after DROP TABLE. Case 1 3

Introduction Human mistakes are inevitable. Wrong “DROP DATABASE” or “DROP TABLE” may destroy critical data on the MySQL server. Backups would help however they’re not always available. This situation is frightening but not hopeless. In many cases it is possible to recover almost all the data that was in the database or table. Let’s look […]


Setting up authentication en masse

Managing many hosts is quite challenging task. There are many tools to solve the problem. My favorite is pdsh. Running a command across a set of hosts is as simple as following: # pdsh -w 192.168.177.[201-208] -R ssh reboot Together with dshbak (which is a part of pdsh package) you can do even cooler things. […]


Recover InnoDB dictionary

Why do we need to recover InnoDB dictionary c_parser is a tool from TwinDB recovery toolkit that can read InnoDB page and fetch records out of it. Although it can scan any stream of bytes recovery quality is higher when you feed c_parser with pages that belong to the PRIMARY index of the table. All […]


UnDROP tool for InnoDB 6

UnDROP tool for InnoDB TwinDB data recovery toolkit is a set of tools that work with InnoDB tablespaces at low level. Incredible Performance of stream_parser stream_parser is a tool that finds InnoDB pages in stream of bytes. It can be either file such as ibdata1, *.ibd or raw partition. stream_parser runs as many parallel workers […]


ibdconnect and secondary keys

ibdconnect is a tool to connect an ibd file to a foreign ibdata file. it’s important to understand how it works as secondary keys may cause interesting behavior. by


InnoDB dictionary

Why Does InnoDB Need Dictionary 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 tables by their names, InnoDB works with integer identifiers. The dictionary stores correspondence between table name and index_id. The […]


About Nagios monitoring in real example

Now it’s time to setup proper monitoring to avoid unpleasant surprises in future. There are two major problems the monitoring solves: alerting and trending. Alerting is to notify a responsible person about some major event like service stopped working. Trending is to track the change of something over time – disk or memory usage over […]


Contain oom-killer

Amazon micro instances is the great start option for small websites. Learn how to contain oom-killer that may make wrong decision. by