AuthMeReloaded icon indicating copy to clipboard operation
AuthMeReloaded copied to clipboard

MySQL 8.0 support

Open rur0 opened this issue 5 years ago • 20 comments

What behaviour is observed:

Server crashes without starting when using MYSQL storage with MYSQL 8 server

What behaviour is expected:

Server to start and run authme smoothly

Steps/models to reproduce:

enable and configure MYSQL with a MYSQL 8 server

Plugin list:

ProtocolLib, SkinsRestorer, AuthMe

Environment description

PaperMC standalone server with AuthMe MYSQL storage

AuthMe build number:

AuthMe v5.5.1-SNAPSHOT-b2214

Error Log:

https://pastebin.com/D4afV6fP

Configuration:

https://pastebin.com/gM6SyHg6

edit: Also, when I am trying to compile AuthMe, I get this error from maven http://i.imgur.com/osz9Nik.png am I missing some repository ?

rur0 avatar Mar 18 '19 23:03 rur0

Spigot's built-in mysql connector doesn't support mysql 8 sadly,, we need to include our own connector library to fix this

sgdc3 avatar Mar 19 '19 22:03 sgdc3

So in the meantime I can use any mysql version that is not 8. Or is there a recommended version ?

rur0 avatar Mar 22 '19 13:03 rur0

Yes

ljacqu avatar Mar 22 '19 19:03 ljacqu

You could also use MariaDB. It's a fork of MySQL and largely replaced the mysql package in many Linux distributions. However MariaDB 10+ is a major release and it could also contain breaking changes like in MySQL 8 from 5.7.

games647 avatar Mar 13 '20 14:03 games647

BTW I noticed that the MySQL connector Spigot currently uses should support MySQL 8. The fix should be included in Connector 5.1.44. This is available in Spigot 1.12.2+

games647 avatar Mar 13 '20 14:03 games647

I'm having this problem too with the latest build downloaded from the CI, please fix

tommasobenatti avatar Mar 11 '21 14:03 tommasobenatti

@tommasobenatti which MC version is your server at?

sgdc3 avatar Apr 08 '21 23:04 sgdc3

@tommasobenatti which MC version is your server at?

Paper 1.8.8, with 1.12.2 there isn't this problem

tommasobenatti avatar Apr 08 '21 23:04 tommasobenatti

@tommasobenatti please try using the "legacy" jar here: https://ci.codemc.io/job/AuthMe/job/AuthMeReloaded/

sgdc3 avatar Apr 09 '21 00:04 sgdc3

@tommasobenatti @rur0 Can somebody please test the legacy jar?

sgdc3 avatar Apr 12 '21 09:04 sgdc3

Sorry, at the moment I'm very busy and I can't test

tommasobenatti avatar Apr 13 '21 08:04 tommasobenatti

@sgdc3 I've tested legacy and normal version on tuinity 1.16.5. It doesn't work with MariaDB 10 https://pastebin.com/Tf3igqeS

r3cord avatar Apr 22 '21 20:04 r3cord

I think that you should test on a 1.8 server @r3cord

tommasobenatti avatar Apr 22 '21 21:04 tommasobenatti

Their issue is related to #2303 and 1.8 is obsolete anyway.

krusic22 avatar Apr 22 '21 21:04 krusic22

@tommasobenatti ohh so there is no fix for this problem in not legacy version of the plugin?

r3cord avatar Apr 22 '21 21:04 r3cord

This issue was created because AuthMe wasn't working on 1.8 and MySQL 8 afaik

tommasobenatti avatar Apr 22 '21 21:04 tommasobenatti

Since 1.8 is older than MySQL 8 and it dosn't include the library to connect to the database. In fact the plugin works fine with 1.12 and MySQL 8 because the libraries are updated in the Paper Jar

tommasobenatti avatar Apr 22 '21 21:04 tommasobenatti

@krusic22 Yeah you're right. Thank you very much! I've had to change com.mysql.jc.jdbc.Driver to com.mysql.jdbc.Driver and now it works. @tommasobenatti yeah my fault, this thread wasn't correlating to my problem. Sorry!

r3cord avatar Apr 22 '21 21:04 r3cord

Modify POM

mysql mysql-connector-java 8.0.xx true

package jar

Modify config.yml mySQLDriverClassName: com.mysql.cj.jdbc.Driver mySQLDatabase: xxx?serverTimezone=xxx

I use this method

NanoNM avatar Apr 26 '21 09:04 NanoNM

Version

Paper 1.16.5 build777 AuthMeReloaded v5.6.0-beta2 (build: 2453) MYSQL 8 Ubuntu 2004

Error

Sometimes startup with ERROR, especially after starting up the server or restarting mysql:

Solution

in MYSQL: ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY 'Your New Password'; guided by this post: https://qiita.com/shaching/items/5fe3d5df691b4ec53084

RuofengX avatar Jul 08 '21 02:07 RuofengX