MAMP mysql 未启动

MAMP mysql not starting

Got error: 2002: Can't connect to local MySQL server through socket '/Applications/MAMP/tmp/mysql/mysql.sock' (2) when trying to connect 150629 15:44:35 mysqld_safe Starting mysqld daemon with databases from /Applications/MAMP/db/mysql 150629 15:44:35 [Warning] You have forced lower_case_table_names to 0 through a command-line option, even though your file system '/Applications/MAMP/db/mysql/' is case insensitive. This means that you can corrupt a MyISAM table by accessing it with different cases. You should consider changing lower_case_table_names to 1 or 2 150629 15:44:35 [Note] Plugin 'FEDERATED' is disabled. 150629 15:44:35 [Note] Plugin 'ndbcluster' is disabled. /Applications/MAMP/Library/libexec/mysqld: Can't find file: './mysql/plugin.frm' (errno: 13) 150629 15:44:35 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it. 150629 15:44:35 InnoDB: Started; log sequence number 1 402900962 150629 15:44:35 [ERROR] /Applications/MAMP/Library/libexec/mysqld: Can't find file: './mysql/host.frm' (errno: 13) 150629 15:44:35 [ERROR] Fatal error: Can't open and lock privilege tables: Can't find file: './mysql/host.frm' (errno: 13) 150629 15:44:35 mysqld_safe mysqld from pid file /Applications/MAMP/tmp/mysql/mysql.pid ended

我在任何地方都找不到 mysql.sock 文件。这是 OS X 版本 10.8.5

上的 MAMP 1.9

首先要尝试更改 MySQL 的数据目录的所有权,例如,如果您 运行 MySQL 与用户 mysql:

chown -R mysql:mysql /path/to/datadir

检查/Applications/MAMP/tmp/mysql/目录创建socket的权限