MySQL服务器启动错误'服务器退出而不更新PID文件'

2022-01-30 00:00:00 mysql

On Mac OS X v10.6 (Snow Leopard), starting MySQL gives the following error:

The server quit without updating PID file

File my.cnf

[mysqld]
port            = 3306

socket          = /tmp/mysql.sock

skip-external-locking

key_buffer_size = 16K

pid-file=/var/run/mysqld/mysqld.pid

[mysqld_safe]

log-error=/var/log/mysqld.log

pid-file=/var/run/mysqld/mysqld.pid

解决方案

Try to remove the ib_logfile0 and ib_logfile1 files and then run MySQL again:

rm /usr/local/var/mysql/ib_logfile0
rm /usr/local/var/mysql/ib_logfile1

It works for me.

相关文章