春哥 发表于 2016-6-21 14:23:25

《windows无法启动MySQL服务 错误1067:进程意外终止》的解决方法

导致这个问题的原因可能不止一种,所以网上搜集的很多方法未必适合一些朋友解决此问题,以下是网上的朋友提供的解决方法,供大家参考:春哥亲测第一种成功解决问题。一、
1、打开my.ini文件,找到default-storage-engine=InnoDB这一行,把它改成default-storage-engine=MyISAM。
2、删除在MySQL安装目录下的Data目录中的ib_logfile0和ib_logfile1

3。找到在配置MySQL服务器时指定的InfoDB目录删除掉ibdata1
根据my.ini文件中:#*** INNODB Specific options ***
      innodb_data_home_dir="D:/"。
4。重新启动MySQL的Service

二、
MySQL在安装的时候不会自动初始tmpdir(临时文件目录),所以要在配置文件my.ini中添加如下内容:        #自己指定的临时文件目录    tmpdir="D:/MySQL/MySQL Server 5.1/Temp"    再次启动MySQL一切正常的话,在Temp文件夹下生成了一些*.tmp的临时文件。    最后还是存在一些疑问:如果是由于没有初始化tmpdir造成的,那为什么在第一次安装的时候没有初始化,却不会出现这样的问题呢?
三、
网上有人说把my.ini放到C:\WINDOWS下或者修改它的某些内容就可以了,但我遇到的问题仍然没有解决。下面的也是网上提供的一种解决方法,是将参数中的--defaults-file用--defaults-extra-file取代,如下:      mysqld --install MySQL --defaults-file=E:/mysql-5.0.83-win32/my.ini      改为      mysqld --install MySQL --defaults-extra-file=E:/mysql-5.0.83-win32/my.ini执行mysqld --verbose --help能看到mysqld的用法,其中就有这两个参数的说明。
经过以上种种测试,我的问题依然没有得到解决,难道就非要重装MySQL了吗,在苦苦搜寻中终于找到了问题的症结:当遇到问题的时候,我们首先想到的应该是去查看错误日志,而不是不加思索地去Google、baidu,其实从错误日志中我们能得到真正造成问题的原因,对症下药,才能药到病除。MySQL的错误日志(.err)位于C:\ProgramData\MySQL\MySQL Server 5.5\data目录下,文件名一般为你的计算机名。
以下是我的错误日志中最后显示的信息,而且重复出现
110513 21:24:25 Plugin 'FEDERATED' is disabled.
InnoDB: The InnoDB memory heap is disabled
InnoDB: Mutexes and rw_locks use InnoDB's own implementation
InnoDB: Compressed tables use zlib 1.2.3
110513 21:24:26InnoDB: highest supported file format is Barracuda.
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
110513 21:24:26InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
110513 21:24:26InnoDB: Warning: allocated tablespace 1, old maximum was 0
InnoDB: Error: trying to add tablespace 27 of name '.\rocro_com\ecs_order_back_list.ibd'
InnoDB: to the tablespace memory cache, but tablespace
InnoDB: 27 of name '.\huayuan\customers_wishlist.ibd' already exists in the tablespace
InnoDB: memory cache!
110513 21:25:19 Buffered information: Performance schema disabled (reason: start parameters).
在此很明显的可以看到'.\rocro_com\ecs_order_back_list.ibd'跟 '.\huayuan\customers_wishlist.ibd'这两个数据库在读取数据空间时发生了错误,于是我把其中一个数据库先移走,然后启动MySQL Server,http://b.bst.126.net/common/portrait/face/preview/face1.gif 奇迹在此出现了,MySQL Server启动成功 http://b.bst.126.net/common/portrait/face/preview/face41.gif然后再把刚才移走的数据库放回去.....OK,至此迷惑很久的Mysql “错误1067:进程意外终止”终于搞定了!!!

页: [1]
查看完整版本: 《windows无法启动MySQL服务 错误1067:进程意外终止》的解决方法