“错误 1067:进程意外终止”当尝试启动 MySQL 时
我正在使用 Windows 7 并运行 XAMPP MySQL SVC 服务。我看到以下错误:
Windows 无法启动本地计算机上的 Mysql 服务。
错误 1067:进程意外终止。
这是什么意思?我该如何解决它?
I'm using Windows 7 and running XAMPP MySQL SVC service. I'm seeing the following error:
Windows could not start the Mysql service on Local Computer.
Error 1067: The process terminated unexpectedly.
What does this mean, and how can I fix it?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(18)
您需要:
mysql path\data
ib_logfile0
和ib_logfile1
。You need to:
mysql path\data
ib_logfile0
andib_logfile1
.检查错误日志(启动 eventvwr.msc)。 MySQL 通常会向应用程序日志写入一些内容。
在极少数情况下,它不会写任何内容(我只知道一个特定的错误 http: //bugs.mysql.com/bug.php?id=56821,其中服务根本无法工作)。还有一个错误日志文件,通常在数据目录中命名为 .err,其信息与写入 Windows 错误日志的信息相同。
Examine error log (start eventvwr.msc). MySQL typically writes something to the Application log.
In very rare cases it does not write anything (I'm only aware of one particular bug http://bugs.mysql.com/bug.php?id=56821, where services did not work at all). There is also error log file, normally named .err in the data directory that has the same info as written to windows error log.
我也有同样的问题。我使用的是mysql 5.6.11。
为了解决这个问题,我必须更改 mysql-5.6.11-win32 文件夹中的 my-default.ini 文件
所以我只是将以下行粘贴到行 [mysqld]
选项 basedir 和 datadir 下,需要修改 mysql 位置。
I had the same problem. I am using mysql 5.6.11.
To solve this problem I had to change my-default.ini file in mysql-5.6.11-win32 folder
So I just pasted the following lines under line [mysqld]
Options basedir and datadir need to be modified for mysql location.
不要忘记检查
my.ini 文件。这两个变量的错误设置值会使 mysql 进程终止并产生错误
1067
。另请检查eventvwr.msc
和mysql_error.log
以了解详细错误。Don't forget to check
on my.ini files. Wrong set value for these two variable make mysql process terminated and produce error
1067
. Also checkeventvwr.msc
andmysql_error.log
for detail error.我遇到了同样的问题,但我对 @Vladislav 的答案感到困惑,并且似乎无法从中找到解决方案。当然,我的问题可能与我尝试升级 XAMPP 时遇到的问题不完全相同,但它也给出了相同的 Error 1067 消息。
通过进一步搜索,我发现了这个:
https ://serverfault.com/questions/214435/error-1067-the-process-termerated-unexpectedly-when-trying-to-install-mysql-on
答案很简单,那就是完全清理文件夹,这并不总是发生。至于XAMPP,我想我首先备份了必要的文件(mysql文件夹中的数据文件夹和htdocs文件夹)。卸载 XAMPP。检查 xampp 文件夹中是否有任何剩余内容并删除所有内容。您可能想稍后重新启动,以防万一。然后重新安装 XAMPP。将备份的文件夹复制回各自的位置,希望 mySql 能够在 XAMPP 中再次运行。
这应该可以解决问题。
I had the same problem but I was confused with @Vladislav's answer and couldn't seem to find the solution from that. Of course, my problem may not be exactly the same as I encountered the problem when trying to upgrade XAMPP, but it also gave the same Error 1067 message.
With further search I found this:
https://serverfault.com/questions/214435/error-1067-the-process-terminated-unexpectedly-when-trying-to-install-mysql-on
The answer from that is straightforward, that is, to completely clean up the folder, which doesn't always happen. As in regards to XAMPP, I guess I backed up the necessary files first (data folder from mysql folder and the htdocs folder). Uninstall XAMPP. Check the xampp folder for any content that remains and delete everything. You may want to reboot afterwards, just in case. Then reinstall XAMPP. Copy the backed-up folders back to their respective places, and hopefully, mySql will work again in XAMPP.
This should solve the issue.
这里同样的问题。通过 eventvwr.msc 分析日志报告后,我发现日志文件放置在需要管理员权限才能更新的文件夹中,因此无法创建文件,安装和启动过程无法继续。
所以检查事件日志非常有用。
Same problem here. After analysing log reports via eventvwr.msc I found, that logging files were placed in folder which requires admin rights to update, so files cannot be created and install and startup process could not proceed.
So checking eventlog was very usefull.
我时常遇到这个问题,当我遇到这个问题时,我已经能够通过使用出现问题的数据库文件夹的备份来解决它。
当您检查“事件查看器>”时Windows 日志 >应用程序”,如果您看到错误:
InnoDB:尝试打开先前打开的表空间。上一个表空间 [数据库]/[表] 使用空间 ID:59,文件路径:.\[数据库]\[表].ibd。无法打开表空间 [不同的数据库]/[不同的表],它在文件路径: .\[不同的数据库]/[不同的表].ibd 使用空间 ID:59
那么对我有用的是删除第一个提到的 [ MySQL 数据目录中的 [database] 文件夹,然后将该数据库文件夹的备份复制到之前的位置。
然后启动MySQL,它再次为我启动,没有这个1067错误。
I get this problem from time to time, and when I do, I have been able to solve it by using a backup of the database folder(s) that give the problem.
When you check your 'Event Viewer > Windows Log > Application', if you see an error:
InnoDB: Attempted to open a previously opened tablespace. Previous tablespace [database]/[table] uses space ID: 59 at filepath: .\[database]\[table].ibd. Cannot open tablespace [different db]/[different table] which uses space ID: 59 at filepath: .\[different db]/[different table].ibd
Then what works for me, is delete the first mentioned [database] folder in your MySQL data directory, and copy the backup of that database folder to where it was previously.
Then start MySQL, and it starts again for me, without this 1067 error.
我几乎有同样的问题。在日志文件中我发现:
显然用户表已损坏。我用另一个副本替换了它(user.frm; user.MYD; user.MYI in mysql\data\mysql)
这对我有用。
ps:我正在使用xampp。
I had practically the same problem. in the log file I found this:
Apparently the user table has been corrupted. I replaced it with another copy (user.frm ; user.MYD ; user.MYI in mysql\data\mysql)
and thats works for me.
ps: am using xampp.
搜索并销毁(或谨慎移动)任何影响mysql服务失败的my.ini文件(Windows或程序文件)。还可以使用 netstat 或 portqry 工具检查端口 3306 是否被使用。这应该有帮助。此外,如果存在文件系统问题,您可以运行检查磁盘。
Search and destroy (or move cautiously) any my.ini files (windows or program files), which is affecting the mysql service failure. also check port 3306 is used by using either netstat or portqry tool. this should help. Also if there is a file system issue you can run check disk.
我刚刚经历了同样的问题,并通过以下方式解决了它。
1 - 在win7中找到记录所有mysql问题的.err文件,位于programData\MySQL\MySQL Server 5.6\data\下
2 - 检查文件中的最后条目,在我的例子中,我发现错误来自我前一天在工作台界面中设置为“true”的标志(审核日志)!
3 - 进入 my.ini 文件,并删除audit-log=ON。
4 - 启动mysql服务并且它工作了!
I just went throught same issue and I solved it the following way.
1 - found the .err file which logs all mysql issues, in win7, located under programData\MySQL\MySQL Server 5.6\data\
2 - Check the last entries from the file and, in my case, I found the error was coming from a flag (audit-log) that I set to "true" from the workbench interface the day before!
3 - went into the my.ini file, and removed audit-log=ON.
4 - launched mysql service and it worked!!
我也遇到了同样的问题,对我有用的是这个其他答案。
我没有在这里复制它,因为它不是正确的做法。
基本上是重新安装,确保删除所有内容并使用 32 位版本。
I've got the same problem, and what worked for me is in THIS OTHER ANSWER.
I didn't replicated it here because it is NOT A CORRECT THING TO DO.
Basically is a re-install being sure to delete everything very well and using 32 bit versions.
我有同样的错误。我检查了错误日志:
C:\ProgramData\MySQL\MySQL Server 5.5\data\inf3rno-PC.err
。根据他们的说法,我认为这里重要的部分是
我将
TMP
和TEMP
环境变量从C:\Windows\Temp
更改为%昨天 USERPROFILE%\AppData\Local\Temp
,因为我无法压缩目录,根据许多帖子,解决方案是这样的。现在压缩可以工作,但是 mysql 和显然 nod32 抱怨它们无法创建临时文件...我将 tmpdir=c:/server/mytmp 添加到 C:\Program Files\MySQL\MySQL Server 5.5\my.ini。然后使用 services.msc 再次启动服务。现在没事了。
所以这也可能是一个可能的原因。我强烈建议遇到此问题的每个人检查错误日志。
I had the same error. I checked the error logs:
C:\ProgramData\MySQL\MySQL Server 5.5\data\inf3rno-PC.err
. According to themI think the important part here
I changed the
TMP
andTEMP
env variables fromC:\Windows\Temp
to%USERPROFILE%\AppData\Local\Temp
yesterday, because I was unable to compress a directory and according to many post the solution is that. Now compression works, but mysql and apparently nod32 complains that they cannot create temporary files...I added
tmpdir=c:/server/mytmp
toC:\Program Files\MySQL\MySQL Server 5.5\my.ini
. And after that started the service again with services.msc. It is okay now.So this can be a possible cause as well. I strongly suggest to everybody encountering this problem to check the error logs.
我使用安装文件来修复。这对我有用
I use install file to repair. it works for me
请检查存储数据库的驱动器上的可用空间。就我而言,由于驱动器空间较少,服务已停止。
please check the space available on drive where the db is stored. in my case it was stopped the service due to less space on drive.
这个问题有很多解决方案。这对我有用
右键单击服务 ->属性->以系统帐户登录。
There are many solutions for the problem. This worked for me
Right click on Service -> Properties -> Log on as system account.
关于这篇文章我的问题已经解决。
我按照以下步骤操作。
祝您好运!
Regarding this article my problem has been solved.
I followed the below steps.
Good luck!
停止 MySQL 服务。
从
“C:\xampp\mysql\backup”复制并替换文件夹
。“mysql”
到“C:\xampp\mysql\data”
100% 工作
Stop the MySQL service.
Copy and replace folder
"mysql"
from"C:\xampp\mysql\backup"
to
"C:\xampp\mysql\data"
.100% working
在 win8 的 XAMPP 服务器中运行 mysql 的错误原因对我来说就是这样。
如果在 XAMPP 中安装 MariaDB First Stop MySql
并安装 MariaDB 时显示错误,那么现在没有问题了...祝你有美好的一天...
error reason running mysql in XAMPP server in win8 thats hapen for me.
if error display when you install MariaDB First Stop MySql in XAMPP
and install MariaDB there is not problem now...have a nice day...