XAMPP 的MYSQL无法启动

 最近在学习小程序,小程序的后台cms系统需要安装XAMPP软件,这个软件是个集成软件,里面有MySql 和 Apache 等 ,首先进入小程序后台时需要启动MySql 和 Apache 

Apache 直接就启动了 MySql 却一直启动不了  开始的时候是因为我之前安装过MySql ,所以路径是不对的 ,解决这个问题最简便的方式就是把之前的卸载了,再安装XAMPP,

第二种方式就是 更改路径:

打开注册表

cmd 

regedit

找到

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\MySQL] 中的ImagePath 修改成你当前的mysqld的执行目录

类似:"D:\xampp\mysql\bin\mysqld"

重新启动服务器成功!

更改之后重启还是没有成功  , MySql 重启几秒又关闭了,还是不成功呢 报错信息

22:59:43  [mysql]     Attempting to start MySQL app...
22:59:43  [mysql]     Status change detected: running
22:59:44  [mysql]     Status change detected: stopped
22:59:44  [mysql]     Error: MySQL shutdown unexpectedly.
22:59:44  [mysql]     This may be due to a blocked port, missing dependencies, 
22:59:44  [mysql]     improper privileges, a crash, or a shutdown by another method.
22:59:44  [mysql]     Press the Logs button to view error logs and check
22:59:44  [mysql]     the Windows Event Viewer for more clues
22:59:44  [mysql]     If you need more help, copy and post this
22:59:44  [mysql]     entire log window on the forums

又通过各种查找 解决方法前提是先把Apache停止运行,第一步先在mysql文件里面找到mysql_installservice.bat和mysql_uninstallservice.bat 两个文件,先双击mysql_installservice.bat,然后关闭,再双击mysql_uninstallservice.bat 关闭,第二步把mysql>data>ibdata1、ib_logfile1、ib_logfile0  这几个文件都删除掉 ,然后重启xampp,就可以成功运行了。

posted on 2017-01-16 11:17  你是我支撑下去的理由  阅读(625)  评论(0编辑  收藏  举报