我已经擦除并安装了OSX 10.11 El Capitan
,我一直在按照本教程在新的 OS X上MySQL
启动和运行。第一步是下载MySQL For Mac OS X 10.9(x86,64 位),DMG 存档(适用于 10.11 ,他们在教程中推荐)。当我完成安装 MySQL 时,我收到消息说:
2015-10-25T02:10:54.549219Z 1 [Note] A temporary password is generated for root@localhost: R>gFySuiu23U
If you lose this password, please consult the section How to Reset the Root Password in the MySQL reference manual.
很奇怪,我从来没有见过这样的消息。之后,我通过 Preference Pane 启动 MySQL,然后/usr/local/mysql/bin/mysql -v
在终端上使用命令进行下一步。我收到一条错误消息:
ERROR 1045 (28000): Access denied for user 'cheetah'@'localhost' (using password: NO)
我还尝试通过Sequel Pro
使用 root 作为用户名和空白密码来访问数据库,我收到拒绝访问的消息说:
Unable to connect to host 127.0.0.1 because access was denied.
Double-check your username and password and ensure that access from your current location is permitted.
MySQL said: Access denied for user 'root'@'localhost' (using password: NO)
好的,我也再次尝试使用 root 作为用户名,但使用“R>gFySuiu23U”作为密码(从 MySQL 生成)。我收到连接失败消息说:
Unable to connect to host 127.0.0.1, or the request timed out.
Be sure that the address is correct and that you have the necessary privileges, or try increasing the connection timeout (currently 10 seconds).
MySQL said: Your password has expired. To log in you must change it using a client that supports expired passwords.
我该如何解决这个问题?我记得 MySQL 从来没有像这样自动生成临时密码,不是吗?