mac mysql报错:The server quit without updating PID file (/usr/local/var/mysql/mac_name.local

作者: php 发布时间: 2021-09-23 浏览: 157 次 编辑

场景:macA更换为macB,使用“迁移助理”迁移所有数据,redis、zk、kafka等都可用,唯独mysql报错。

启动:

mysql.server start

报错:

ERROR! The server quit without updating PID file (/usr/local/var/mysql/***.local.pid)

解决:

详细Stack Overflow

其实就是把mysql删的干干净净,然后重装

brew remove mysql
brew cleanup
launchctl unload -w ~/Library/LaunchAgents/homebrew.mxcl.mysql.plist
rm ~/Library/LaunchAgents/homebrew.mxcl.mysql.plist
sudo rm -rf /usr/local/var/mysql

brew install mysql
mysql.server start # no sudo!