Mac启动MySQL失败,报错信息:Warning:The /usr/local/mysql/data directory is not owned by the 'mysql' or '_mysql' user

Mac启动MySQL失败,报错信息:Warning:The /usr/local/mysql/data directory is not owned by the ‘mysql’ or ‘_mysql’ user

问题描述

Mac在MySQL启动或开机自动运行时,报错,如下图

在MySQL操作面板上会提示“Warning:The /usr/local/mysql/data directory is not owned by the ‘mysql’ or ‘_mysql’”

分析原因

Mac OS X的升级或其他原因可能会导致MySQL启动或开机自动运行时出错。

解决方法

应该是某种情况下导致/usr/local/mysql/data的宿主发生了改变

mac 下面运行 “sudo chown -R_mysql:wheel/usr/local/mysql/data

即可正常启动:

https://stackoverflow.com/questions/5527676/warning-the-user-local-mysql-data-directory-is-not-owned-by-the-mysql-user
https://blog.csdn.net/lvsijian8/article/details/60779386

-------------本文结束感谢您的阅读-------------

本文标题:Mac启动MySQL失败,报错信息:Warning:The /usr/local/mysql/data directory is not owned by the 'mysql' or '_mysql' user

文章作者:Cryptohkk

发布时间:2019年03月06日 - 21:03

最后更新:2019年03月06日 - 21:03

原始链接:https://hkkhuang.cn/2019/03/06/Mac启动MySQL失败,报错信息:Warning-The-usr-local-mysql-data-directory-is-not-owned-by-the-mysql-or-mysql-user/

许可协议: 署名-非商业性使用-禁止演绎 4.0 国际 转载请保留原文链接及作者。