Relay log read failure: Could not parse relay log event entry. The possible reasons are: the master’s binary log is corrupted

To Resolve such kind of issue, check the master relay log as follow; mysql> slave stop; Query OK, 0 rows affected (0.00 sec) mysql> change master to master_log_file=’mysql-bin.000001′,master_log_pos=207078754; Query OK, 0 rows affected (0.04 sec) mysql> start slave; Query OK, 0 rows affected (0.00 sec) Now you can check , Slave should start working.

MySQL Replication Slave I/O Thread States

Waiting for master update The initial state before Connecting to master. Connecting to master The thread is attempting to connect to the master. Checking master version A state that occurs very briefly, after the connection to the master is established. Registering slave on master A state that occurs very briefly after the connection to the … Read more

Change default MySQL Data Directory in Linux

Mostly MySQL uses /var/lib/mysql directory as default data directory for Linux based systems We are showing here how to change the default directory to different directory. Follow the below steps to make all the changes. In some cases service name, default data directory or MySQL configuration file path change. So use all the command as … Read more

Dumping MySQL Stored Procedures, Functions and Triggers

MySQL  has introduced some new interesting features, like stored procedures and triggers. I will show in this small post how we can backup and restore these components using mysqldump. What is Stored Procedure ? A stored procedure, by definition, is a segment of declarative SQL code which is stored in the database catalog and can … Read more

How can I stop a running MySQL query?

I connect to mysql from my Linux shell. Every now and then I run a SELECT query that is too big. It prints and prints and I already know this is not what I meant. I would like to stop the query. Hitting Ctrl+C (a couple of times) kills mysql completely and takes me back … Read more