系统更新之后,XAMPP自带的MySQL就启动不了,以为是补丁引起的。报错如下:
[mysql] This may be due to a blocked port, missing dependencies,
[mysql] improper privileges, a crash, or a shutdown by another method.
[mysql] Press the Logs button to view error logs and check
[mysql] the Windows Event Viewer for more clues
[mysql] If you need more help, copy and post this
[mysql] entire log window on the forums
查了一下端口,没有被占用;
看Error Log,没看懂;
看Windows事件,以为是用户名、密码问题,修改my.ini,添加Master用户名、密码,显示配置文件错误;
回到Error Log,留意到一处错误重复出现:
': Slave I/O: Fatal error: Invalid (empty) username when attempting to connect to the master server. Connection attempt terminated. Internal MariaDB error code: 1593
搜索一下,终于找到了一个解决方案:
在mysql未启动的情况下,检查是否存在xampp/mysql/data/multi-master.info文件,并将其删除。这对我很有效。
删除multi-master.info之后果然能启动了!
来源:https://cloud.tencent.com/developer/ask/sof/1159042