您的位置:首页 > 其它

Incorrect key file for table解决方法

2010-08-16 13:35 555 查看
org.springframework.dao.DataIntegrityViolationException: SqlMapClient operation; SQL [];

--- The error occurred in sql/Scene.xml.

--- The error occurred while applying a parameter map.

--- Check the insertBoxLogTmp-InlineParameterMap.

--- Check the statement (update failed).

--- Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Duplicate entry '2607-200305' for key 'PRIMARY'; nested exception is com.ibatis.common.jdbc.exception.NestedSQLException:

--- The error occurred in sql/Scene.xml.

--- The error occurred while applying a parameter map.

--- Check the insertBoxLogTmp-InlineParameterMap.

--- Check the statement (update failed).

--- Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Duplicate entry '2607-200305' for key 'PRIMARY'

Caused by: com.ibatis.common.jdbc.exception.NestedSQLException:

--- The error occurred in sql/Scene.xml.

--- The error occurred while applying a parameter map.

--- Check the insertBoxLogTmp-InlineParameterMap.

--- Check the statement (update failed).

--- Cause: com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Duplicate entry '2607-200305' for key 'PRIMARY'

at com.ibatis.sqlmap.engine.mapping.statement.MappedStatement.executeUpdate(MappedStatement.java:107)

at com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate.insert(SqlMapExecutorDelegate.java:393)

at com.ibatis.sqlmap.engine.impl.SqlMapSessionImpl.insert(SqlMapSessionImpl.java:82)

at org.springframework.orm.ibatis.SqlMapClientTemplate$9.doInSqlMapClient(SqlMapClientTemplate.java:370)

at org.springframework.orm.ibatis.SqlMapClientTemplate.execute(SqlMapClientTemplate.java:194)

at org.springframework.orm.ibatis.SqlMapClientTemplate.insert(SqlMapClientTemplate.java:368)

at com.manu.tarot.dao.SceneDao.insertBoxLogTmp(SceneDao.java:151)

at com.manu.tarot.service.BoxService.insertBoxLogTmp(BoxService.java:94)

at com.manu.tarot.service.BoxService$$FastClassByCGLIB$$dbf8e40d.invoke(<generated>)

at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)

查看mysql error日志, 提示一张日志表损坏,需要修复

091120 16:40:50 [ERROR] /usr/sbin/mysqld: Incorrect key file for table './sword/Sword_log.MYI'; try to repair it

停掉相关服务,冷备数据库后,执行check table Sword_log及repair table Sword_log后恢复。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  笔记 file table key Incorrect