简体   繁体   中英

Connection between DBeaver & MySQL

I use DBeaver to watch an SQL database on MySQL 8+.

Everything is working, but sometimes, opening DBeaver, I have the following error message:

Public Key Retrieval is not allowed

And then, DBeaver can't connect to MySQL.

In order to fix this problem, I have to reconfigure MySQL.

Is there any simplest way to fix this problem?

Change the settings on Dbeaver:

  1. Right click your connection, choose "Edit Connection"
  2. On the "Connection settings" screen (main screen) click on "Edit Driver Settings" 在此处输入图像描述
  3. Click on "Connection properties"
  4. Right click the "user properties" area and choose "Add new property"
  5. Add two properties: "useSSL" and "allowPublicKeyRetrieval" 在此处输入图像描述
  6. Set their values to "false" and "true" by double clicking on the "value" column
  7. Save and test the connection.

Hopefully it should work!

Edit Connection

click second tab "Driver Properties"

Change property allowPublicKeyRetrieval = True

Connection settings/Driver properties:

在此处输入图像描述

Did you try explicitly allowing public key retrieval in DBeaver? In the connection settings, SSL tab you can find it

在此处输入图像描述

This is in case you are using SSL, otherwise in the same screen you can disable SSL by unchecking "use SSL" and "require SSL"

Ratish Bansal's solution works for me on MacOS Mojave, and after that , I always get a timezone error. The solution for that is to set my local timezone in the connection settings :

在此处输入图像描述

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM