app教程网 学习教程 mysql kill process(kill mysql进程)

mysql kill process(kill mysql进程)

无法初始化tc日志,中止| mysql事务日志导致启动失败。killall mysql进程后,mysql无法启动问题汇总;

问题1:

杀死杀死mysql进程后,重启,无法启动,报错:

110303 14:01:45 InnoDB: Started; log sequence number 0 138710263

/usr/local/MySQL/bin/mysqld:File .找不到/MySQL-bin。000041'(错误代码:13)

110303 14:01:45[ Error] Unable to open the log (file). /mysql-bin.000041' error number 13)

110303 14:01:45 [ERROR] Could not open log file

110303 14:01:45[ Error] Unable to initialize tc log.

110303 14:01:45 [ERROR] Aborting

在mysql/data/目录下找到mysql-bin.000041文件,删除,重启,还是不行,报错:

110303 14:04:07 InnoDB: Started; log sequence number 0 138710263

/usr/local/MySQL/bin/mysqld:File .找不到/MySQL-bin。000041'(错误代码:2)

110303 14:04:07[ Error] Unable to open the log (file). /mysql-bin.000041' error number 2)

110303 14:04:07 [ERROR] Could not open log file

110303 14:04:07[ Error] Unable to initialize tc log.

110303 14:04:07 [ERROR] Aborting

触摸,修改权限,重启,也不行,错误:

110303 14:05:41 InnoDB: Started; log sequence number 0 138710263

110303 14:05:41 [ERROR] I/O error reading the header from the binary log, errno=-1, io cache code=0

110303 14:05:41 [ERROR] I/O error reading the header from the binary log

110303 14:05:41[ Error] Unable to initialize tc log.

110303 14:05:41 [ERROR] Aborting

最终解决方案:

删除mysql/data/mysql-bin.index文件,重启mysql,会自动生成一个新的mysql-bin.index文件。启动成功。

问题2:

启动后,报告错误:

InnoDB: Started; log sequence number 0 1004308157

110303 14:15:01 [Note] Recovering after a crash using mysql-bin

110303 14:15:01[错误]Log _ event:read _ Log _ event()中的错误:"读取错误",数据长度:169,事件类型:2

110303 14:15:01[ Note] Crash recovery started …

110303 14:15:01 [Note] Crash recovery finished.

/opt/31306/mysql/bin/mysqld: The disk is full. /mysql-bin。 ~rec~' (error code: 28). Waiting for someone to free up space . (After freeing disk space, the server is expected to continue running for up to 60 seconds)

这是因为mysql-bin日志太多了。进入mysql/data/目录后,所有mysql-bin。*文件果断删除,启动成功。

问题3:

启动后,报告错误:

110303 14:21:37 InnoDB: Started; log sequence number 0 487312871

110303 14:21:37[ Error] Unable to start the server on TCP/IP port: Bind: the address has been used.

110303 14:21:37 [ERROR] Do you already have another mysqld server running on port: 43306 ?

110303 14:21:37 [ERROR] Aborting

根据提示,43306端口应该被占用,但是检查后没有发现该端口被占用。没有深究,果断将my.cnf文件中的端口修改为新端口,并重启启动成功。收盘后,

把my.cnf里的端口改回43306,重启,又可以成功启动了。

本文来自网络,不代表本站立场,转载请注明出处:https: