[BUG] MySQL 8 does not work with Prism
hilltty opened this issue ยท 4 comments
Describe the bug
Plugin doesn't work with new MySQL version
To Reproduce
- Download and install MySQL 8
- Enter user and database data into the plugin config
- Reboot server
- And we understand that nothing works
Expected behavior
Everything should work
Server (please complete the following information):
- Prism Version: 2.1.7
- Server Type: Purpur (Paper fork)
- Server Version: 1.16.5
Additional context
To make sure, I checked on Spigot and Paper, the problem is still present.
MySQL 8 works perfectly fine when configured properly.
If you are getting "Public Key Retrieval is not allowed" here are several solutions, most secure to least secure.
- Enable SSL (add
useSSL=true
to the jdbcUrl) and configure it correctly. - Store the server's public key somewhere prism can access it and add
serverRsaPublicKeyFile=<path to the key file>
to the jdbcUrl. - Change the db user to use
mysql_native_password
instead of the defaultcaching_sha2_password
(which became the default in 8). - Add
useSSL=false&allowPublicKeyRetrieval=true
to the jdbcUrl.
All of the jcbcUrl changes can be made in the hikari.properties file
Does the error happen to feature a line similar to:
[08:12:30 ERROR]: [Prism] Hikari Pool did not Initialize: Failed to initialize pool: Public Key Retrieval is not allowed
If so then you have the same issue as me