MySQL

A tale of Corrupt InnoDB table, MySQL crash & recovery

I’m going to narrate you a story that happened around a crashing MyQL, Corrupted InnoDB table and finally the recovery by table restore. We will see how our database administrator detected the issue and what he did to resolve it. A day in MySQL Database Consultant’s day was taking its shape while a friend called for help. Friend: Hey, my mysql is crashing and website isn’t functioning well. Everything is down. Can you help me? Our database admin quickly jumps in and checks for the MySQL error log. 2018-01-01T07:39:03.173398Z 0 [ERROR] InnoDB: Database page corruption on disk or a failed...

MySQL to Galera Cluster Migration, Deadlock, Back to basics

This post is a lab experiment learning from migration to the Percona Xtradb Cluster (Galera) and a very unexpected DEADLOCK scenario which took me back to basics. (root@localhost) [test]>insert into app values (1); ERROR 1213 (40001): Deadlock found when trying to get lock; try restarting transaction Little background: We needed to work on migrating the standard MySQL replication to a Galera (Percona Xtradb Cluster). Previous configuration being one Master with two slaves detailed as follows: server-1: MySQL community 5.6 serving as Master server-2: MySQL community 5.6 serving as Slave server-3: MySQL community 5.6 serving as Slave We wanted to migrate...