I got the below error.
Query partially completed on the master (error on master: 1053) and was aborted. There is a chance that your master is inconsistent at this point. If you are sure that your master is ok, run this query manually on the slave and then restart the slave with SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1; START SLAVE; . Query: 'optimize table '
=================
Now, I researched and got something
Query partially completed on the master (error on master: 1053) and was aborted. There is a chance that your master is inconsistent at this point. If you are sure that your master is ok, run this query manually on the slave and then restart the slave with SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1; START SLAVE; . Query: 'FLUSH TABLES'
Here the server panicked on the "FLUSH TABLES" command.
Research showed the master db was restarted at the time of the error.
It seems perfectly safe to run "FLUSH TABLES" on the slave
Connect to slave database
Run "SHOW SLAVE STATUS;"
Note "Last Erno" field is 1053 and "Last Error" is above error
Run "STOP SLAVE;"
Run "FLUSH TABLES;"
Run "SQL_SLAVE_SKIP_COUNTER=1; START SLAVE;"
Run "SHOW SLAVE STATUS;" and verify "Last Erno" is now 0 (zero) and "Last Error" is blank.
Exit mysql
Run "cat /var/lib/mysql/relay-log.info" a few times and verify the index values are updating. If a long command is running it may take several minutes to see an update
Note: It may take a while for the replication db to catch back up to the primary database.
Continue to monitor occasionally until the mysql-bin.NNNN file in relay-log.info is the same as the latest binlog on the primary database (in /var/lib/mysql). This means the replication has caught back up.
===================================
you can see, they are asking to run "Flush tables" query again on the slave.
while my query was "optimize table ".
Do I really need to run this 'optimize table' query again on my slave ? because i think its too large table and it will stop again.
======================================
OPTIMIZE TABLE
-- it rarely is worth the time.