惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Vercel News
Vercel News
Recorded Future
Recorded Future
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
The GitHub Blog
The GitHub Blog
Application and Cybersecurity Blog
Application and Cybersecurity Blog
Google DeepMind News
Google DeepMind News
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
Microsoft Azure Blog
Microsoft Azure Blog
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
M
MIT News - Artificial intelligence
云风的 BLOG
云风的 BLOG
Y
Y Combinator Blog
N
News | PayPal Newsroom
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Help Net Security
Help Net Security
博客园 - Franky
SecWiki News
SecWiki News
Recent Announcements
Recent Announcements
T
Troy Hunt's Blog
The Register - Security
The Register - Security
The Last Watchdog
The Last Watchdog
Webroot Blog
Webroot Blog
S
Security Affairs
博客园 - 司徒正美
S
Schneier on Security
I
InfoQ
博客园_首页
www.infosecurity-magazine.com
www.infosecurity-magazine.com
T
Threat Research - Cisco Blogs
Forbes - Security
Forbes - Security
腾讯CDC
N
Netflix TechBlog - Medium
N
News and Events Feed by Topic
Cloudbric
Cloudbric
T
The Exploit Database - CXSecurity.com
P
Proofpoint News Feed
A
About on SuperTechFans
Engineering at Meta
Engineering at Meta
Recent Commits to openclaw:main
Recent Commits to openclaw:main
B
Blog
V
Vulnerabilities – Threatpost
C
Check Point Blog
Google DeepMind News
Google DeepMind News
Google Online Security Blog
Google Online Security Blog
C
Cyber Attacks, Cyber Crime and Cyber Security
Hacker News - Newest:
Hacker News - Newest: "LLM"
C
Cisco Blogs
Schneier on Security
Schneier on Security
O
OpenAI News
K
Kaspersky official blog

博客园 - 听棠.NET

别对我撒谎,神奇的“微表情”,你来测测看! 中国人自己的DISC-易为DISC行为风格分析认证专家 如何做好突发公共卫生事件应急指挥与决策系统建设?(突发公卫应急系统建设) 教你如何定制刻录自己喜欢的汽车音乐CD(自定义无损音乐APE格式) 应该让人一眼就能区分球队? 从富士康十连跳看欧美、日韩、台资企业的不同 富士康的十连跳折射出现代人的心理危机 黄颖的“迪诺曼”——上海世博会上的苏州身影 flex 客户端缓存 module swf(转) Flash Builder 4 正式版破解注册方法(flex4) 联网创业六大经典理论:没VC时该想想杂货店[转] 李娜的成长,借助DISC行为模式理论从成功走向下一个成功 [Flex]如何使用registerClassAlias来解决module中使用RemoteObject - 听棠.NET - 博客园 Flex与.NET进行Remoting数据交换时注意的三个问题。 - 听棠.NET - 博客园 人生的45个功课 价值观(职业锚)与职业的选择 职业兴趣测评这么火! 创建ActionScript3的Singleton单例类模型 大学毕业前的自我检查清单
如何移值(恢复、还原)Mysql中的innoDB的数据库。
听棠.NET · 2009-12-23 · via 博客园 - 听棠.NET

今天搞了一天,终于搞定了。

对于Mysql有两种模式,MYISAM与INNODB

如果是MYISAM的话,在data目录下里会.frm .myd .myi 三种文件,那么直接把DATA移过去,配置好权限就可以还原了。

如果是INNODB的话,那是相当的烦啊。在data目录下只有.frm(这只是一个数据格式),这个移过去后,是无法还原原始数据的。

真正的数据是正放在data目录下的iddata1里。因此,如果有这个文件,那么还是有希望还原的。

但我试了网上所有的文章,都还是提示“数据库里没有表”。

最后我找到了答案。那就是my.ini的配置文件。里面有一项:

innodb_data_home_dir="C:\Program Files\MySQL\MySQL Server 5.1\data"

只要把上面的地址设为你正确的地址就可以了。

记得重启一下mysql (在CMD里输入net stop mysql,然后net start mysql)就可以了还原了。。。

我花了一天时间发现的问题,希望能对同样遇到问题的朋友有所帮助。

总结,对于Mysql还是默认采用MYISAM的比较好,容易转移。数据库与数据库是分开的,不会混在一起。所以可以在My.ini里设一下默认项:

default-storage-engine=MYISAM

good luck!!