讨教:通过data文件夹恢复mysql数据库

MySql 码拜 8年前 (2016-05-20) 1620次浏览
各位好,讨教一个mysql恢复的问题。
本人现在有data文件夹下的内容,怎么能恢复出来里面的数据呢?
本人尝试了新建了一个库,把ibdata1  和 旧库对应的文件夹都放进去了,然后删除了ib_logfile*。  启动是成功了,表也都能看到了,但是一打开表,就会报错:incorrect information 或 表不存在。
先谢了!
解决方案

30

ref:
http://dev.mysql.com/doc/refman/5.0/en/innodb-backup.html
this only works for innodb tables, see the data files that you need to have for restore…

10

引用:
Quote: 引用:

ref:
http://dev.mysql.com/doc/refman/5.0/en/innodb-backup.html
this only works for innodb tables, see the data files that you need to have for restore…

您好,这个假如是ndb呢?  能行得通么?

I don”t know…
do you have data files for all ndb nodes? Is this a recovery? where is ur backup?

10

INNODB引擎不支持直接移库的,读出来会报错的 LSN不一样的

10

尝试在配置文件中加入innodb_force_recovery=6来启动看能否可以读出数据

30

引用:
Quote: 引用:

ref:
http://dev.mysql.com/doc/refman/5.0/en/innodb-backup.html
this only works for innodb tables, see the data files that you need to have for restore…

您好,这个假如是ndb呢?  能行得通么?

ndb不行,ndb是存放在内存中的。

10

引用:

NDB的 是怎么恢复呢?

有备份的就能恢复,或ndb假如有磁盘文件也可以恢复,假如没有,那就恢复不了。


CodeBye 版权所有丨如未注明 , 均为原创丨本网站采用BY-NC-SA协议进行授权 , 转载请注明讨教:通过data文件夹恢复mysql数据库
喜欢 (0)
[1034331897@qq.com]
分享 (0)