mysql 安装了最新版本8.0.11后创建用户并授权后,授权的用户连接数据库提示

The server requested authentication method unknown to the client

查阅一些相关的资料后发现是由于新版本的mysql账号密码解锁机制不一致导致的

解决办法:

删除创建的用户和授权,

  1. 找到mysql配置文件并加入
  2. default_authentication_plugin=mysql_native_password

变为原来的验证方式,然后从新创建用户并授权即可

  1. mysql -uroot -p
  2.  
  3. use mysql;
  4. ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY '你的密码';

mysql 8.0 错误The server requested authentication method unknown to the client的更多相关文章

  1. Laravel - 解决连接MySQL时报"The server requested authentication method unknown to the client”错误

    2019-04-12发布:hangge阅读:934   1,问题描述 最近建了个 Laravel 项目,当配置好 MySQL 数据库进行请求时,页面报如下错误:   SQLSTATE[HY000] [ ...

  2. PHP错误:SQLSTATE[HY000] [2054] The server requested authentication method unknown to the client

    使用PHP连接MySQL 8的时候,可能会发生如标题所示的错误: SQLSTATE[HY000] [2054] The server requested authentication method u ...

  3. mysql8.0:SQLSTATE[HY000] [2054] The server requested authentication method unknown to the client

    忽然注意到的情况: 2018/7/19至2018/9/13之间发布的7.1.20.7.1.21.7.1.22和7.2.8.7.2.9.7.2.10这六个版本提供的对caching_sha2_passw ...

  4. php7.3连接MySQL8.0报错 PDO::__construct(): The server requested authentication method unknown to the client [caching_sha2_password]

    报的错误: In Connection.php line : SQLSTATE[HY000] [] The server requested authentication method unknown ...

  5. Warning: mysqli_connect(): The server requested authentication method unknown to the client [caching_sha2_password]报错解决方法

    错误: 解决方法:

  6. PHP Warning: mysqli_connect(): The server requested authentication method unknown to the client [caching_sha2_password] in /usr/local/php/CreateDB.php on line 5

    原因:php还不支持mysql8.0最新的密码加密方式 ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY ' ...

  7. Docker mysql 连接 “The server requested authentication method unknown to the clien”错误

    查了下,出现这个错误的原因是从mysql 5.6开始,mysql密码加密算法更改了. 我装的mysql 8.* ,那么有两种解决方法: mysql 版本选择 <= 5.6 修改密码 docker ...

  8. PHP连接mysql8.0出错“SQLSTATE[HY000] [2054] The server requested authentication method unkno…

    今天安装安装一个叫得推校园O2O系统的使劲都说连接不上服务器. 下面是安装说明,我直接进行3步骤,导入数据库配置文件,结果就显示题目报错的内容 安装说明: 直接输入程序目录即可 http://loca ...

  9. PHP连接mysql8.0出错“SQLSTATE[HY000] [2054] The server requested authentication method unknow.....

    这个错可能是mysql默认使用 caching_sha2_password作为默认的身份验证插件,而不再是 mysql_native_password,但是客户端暂时不支持这个插件导致的. 解决方法一 ...

随机推荐

  1. LOJ3048 「十二省联考 2019」异或粽子

    题意 题目描述 小粽是一个喜欢吃粽子的好孩子.今天她在家里自己做起了粽子. 小粽面前有 $n$ 种互不相同的粽子馅儿,小粽将它们摆放为了一排,并从左至右编号为 $1$ 到 $n$.第 $i$ 种馅儿具 ...

  2. drone 1.0 新的定时任务界面&&构建任务支持重启

    drone 1.0 的定时任务是一个不错的功能,早期的版本是必须使用cron 表达式的 最近发布的版本支持通过配置就可以了,很方便,只是目前比较简单的,支持小时. 天.周.月.年的模式 环境准备 do ...

  3. Airtest Project的探索和使用

    Airtest使用参考博文: https://testerhome.com/topics/12391 1. 安装Python 3 2. 安装pip: 安装方法参考另外一篇随笔 pip3部署: C:\U ...

  4. GoJS 在 vue 项目中的使用

    GoJS 在 html vue 项目中的使用,github地址:https://github.com/cag2050/gojs_demo GoJS 在 vue-cli 2.x 项目中的使用,githu ...

  5. Java的date和string互转

    https://blog.csdn.net/angus_17/article/details/7656631

  6. java zip 压缩文件

    zip压缩:ZipOutputStream.ZipFile.ZipInputStream 三个类的作用 一段 java  zip  压缩的代码: File dir = new File("C ...

  7. 怎么理解Python画图中的X,y

    X_outliers=np.array([[3.4, 1.3], [3.2, 0.8]]) y_outliers=np.array([0, 0]) 要明白X,y不再是我们高中时候学的x,y轴的坐标:首 ...

  8. 关于plot画图的原理

    首先是导入的: Import matplotlib.pyplot as plt 这份导入要背住,没事就是需要你进行导入的: 然后就是画图了,下面举一个例子: import numpy as np im ...

  9. svn already lock解决方法

    svn在pull的时候,出现svn already lock 错误.只需要在Cleanup里面勾选Break locks

  10. VS2015和SVN合作

    SVN就是版本控制管理工具. 插件这里,还是遇到了一些问题,我知道有插件了,但是忽略了开始的版本问题,按时插件安装过程中没有出现意外,故以为“插件安装成功”,岂不知此“成功”非彼“成功”.由于我用的是 ...