Home  >  Article  >  Database  >  数据库-求助一个关于mysql复制的问题

数据库-求助一个关于mysql复制的问题

WBOY
WBOYOriginal
2016-06-06 09:42:481046browse

mysql数据库

各位大神好:

小弟是个新人,接手一个现有系统的维护,因想弄套测试环境想把正在使用的mysql数据库在另一台机器上复制一个,倒腾半天无法成功,求大神答惑。

背景:原服务器是windows2003系统,新服务器的系统相同。
1.首先在新服务上安装了一个mysql数据库,由于不了解原来的数据库配置所以瞎配置了一通,
也就是在运行MySQLInstanceConfig.exe的时候选择的内容可能跟原来的不同。
2.将目标服务器上的mysql通过net stop mysql命令关闭掉了,进程中已无mysql
3.将源服务器中的Mysql文件夹和Mysql_Data文件夹直接拷贝到对应的目标服务器的对应文件夹中,覆盖原来的所有文件。
4.修改my.ini文件,将basedir=修改为目标服务中Mysql文件夹的路径,datadir=修改为目标服务器中的Mysql_Data/Data的路径。
5.运行 net start mysql

出现如下提示:

<code> MySQL 服务正在启动 ...MySQL 服务无法启动。系统出错。发生系统错误 1067.进程意外终止。</code>

6.查看Mysql_Data\data 目录下的err文件发现如下内容:

<code> 150120 15:37:32 [Note] Plugin 'FEDERATED' is disabled.150120 15:37:33  InnoDB: Initializing buffer pool, size = 2.0G150120 15:37:37  InnoDB: Completed initialization of buffer pool150120 15:37:37  InnoDB: Operating system error number 21 in a file operation.InnoDB: Some operating system error numbers are described atInnoDB: http://dev.mysql.com/doc/refman/5.1/en/operating-system-error-codes.htmlInnoDB: File name E:\MySQL-Data\ibdata1InnoDB: File operation call: 'create'.InnoDB: Cannot continue operation.</code>

以上为全部的操作,求大神解答如何mysql数据库无法启动了,我应该怎么处理,谢谢。

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn