-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
使用 MySQL 8.0 执行 ./server 日志出现 MySQL Error #80
Comments
Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' |
我手动建了个软连接 /tmp/mysqld.sock 到 /var/run/mysqld/mysqld.sock |
thanks,救命了 |
不愧是大佬,我就是靠你这个搞定了 |
根据打印日志输出的错误,进一步调试。 |
README 上推荐的 MySQL 版本是 5.7,但是自己虚拟机上的版本是 8.0,踩了个坑,说一下我的解决办法:
第一次运行的时候直接退出了,日志只显示了 MySQL Error 没有更多的信息,然后看了看其他的 Issues 把
localhost
改为127.0.0.1
,依然是 MySQL Error。查看
sql_connection_pool.cpp
,日志输出的内容是由于mysql_real_connect()
这个函数返回为空导致。因为不知道具体错误是什么比较头疼,于是尝试把 MySQL 的错误直接打印出来:于是我得到了
Authentication plugin ‘caching_sha2_password’ cannot be loaded
,错误码是 2059(没仔细琢磨,应该是 MySQL 8.0 才会遇到),可以自己搜一下解决方案,以下是我的办法:然后就可以了。
The text was updated successfully, but these errors were encountered: