链接 MySQL 8.x 版本报错解决

在使用DBeaver链接 MySQL 8.x 版本时碰见了两个问题,经过查询找到了解决方案,记录一下:mysql

问题

问题一

Public Key Retrieval is not allowedsql

解决

在驱动属性里设置 allowPublicKeyRetrieval 的值为 truespa

clipboard.png

问题二

The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration property) to use a more specifc time zone value if you want to utilicode

解决

经过上面的报错信息能够发现是时区的问题,所以只要把时区改成当前系统时区便可。使用root用户登陆mysql,而后执行如下命令:server

  1. show variables like '%time_zone%';
  2. set global time_zone='+8:00'; 设置为北京时区
相关文章
相关标签/搜索