ONLINE DDL - Incorrect Key
Posted by:
G K
Date: July 09, 2018 01:14PM
I am implementing MySQL's - Online DDL to add a column to a table using ALGORITHM=INPLACE to implement 'Zero-Downtime upgrade'. The query I execute is,
ALTER TABLE documentbase_copy ADD testColumn INT, ALGORITHM=INPLACE, LOCK=NONE;
the table sizes are very huge and this query works perfectly fine on tables of size 1 Million or less. But when I tried to run it on table size 10Million, I get the following error -
java.sql.SQLException: Incorrect key file for table 'documentbase_copy'; try to repair it
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:127)
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:95)
at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122)
at com.mysql.cj.jdbc.ClientPreparedStatement.executeInternal(ClientPreparedStatement.java:960)
at com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdateInternal(ClientPreparedStatement.java:1116)
at com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdateInternal(ClientPreparedStatement.java:1066)
at com.mysql.cj.jdbc.ClientPreparedStatement.executeLargeUpdate(ClientPreparedStatement.java:1396)
at com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdate(ClientPreparedStatement.java:1051)
at com.example.Informatica.Threads.EstablishConnection.executeUpdateQuery(EstablishConnection.java:67)
at com.example.Informatica.Threads.QueryThread.run(QueryThread.java:19)
at com.example.Informatica.Threads.QueryThread.call(QueryThread.java:33)
at com.example.Informatica.Threads.QueryThread.call(QueryThread.java:1)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
I am not sure what MySQL means by "incorrect key file for table {}, try to repair it." After reading some blogs, I tried to repair my table, but this is an InnoDB table and cannot be repaired.
Please help!!
P.S - This MySQL server and database is hosted on Amazon - RDS
Thanks in advance!
Subject
Views
Written By
Posted
ONLINE DDL - Incorrect Key
1613
July 09, 2018 01:14PM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.