Traccar cannot connect with mysql

Amado last year

Hello!!!!
I installed traccar 6.6 on a new vps with ubuntu 22.04 and mysql 8.0.40
I copied and existing traccar.xml config file from a working traccar 6.4 server (with mysql)
Traccar 6.6 fails at start up and the log file shows the error " Driver com.mysql.cj.jdbc.Driver claims to not accept jdbcUrl"
What can be wrong?

Anton Tananaev last year

Logs please.

Anton Tananaev last year

And also provide your config, at least the database part.

Amado last year

traccar.xml configuration:

<entry key='database.driver'>com.mysql.cj.jdbc.Driver</entry>
<entry key='database.url'>jdbc:mysql://localhost:3306/traccar?zeroDateTimeBehavior=round&amp;serverTimezone=
UTC&amp;allowPublicKeyRetrieval=true&amp;useSSL=false&amp;allowMultiQueries=true&amp;autoReconnect=true&amp;useUnicode
=yes&amp;characterEncoding=UTF-8&amp;sessionVariables=sql_mode=''</entry>
<entry key='database.user'>xxxx</entry>
<entry key='database.password'>xxxx</entry>

Log errors:

2025-01-16 14:35:42  INFO: Version: 6.6
2025-01-16 14:35:42  INFO: Starting server...
2025-01-16 14:35:42  INFO: HikariPool-1 - Starting...
2025-01-16 14:35:43 ERROR: Main method error - Driver com.mysql.cj.jdbc.Driver claims to not accept jdbcUrl, jdbc:mysql
://localhost:3306/traccar?zeroDateTimeBehavior=round&serverTimezone=
UTC&allowPublicKeyRetrieval=true&useSSL=false&allowMultiQueries=true&autoReconnect=true&useUnicode
=yes&characterEncoding=UTF-8&sessionVariables=sql_mode='' - RuntimeException (... < DatabaseModule:80 < <gener:-1 < *:
-1 < ... < MainModule:138 < <gener:-1 < ...)
Anton Tananaev last year

Why do you have a bunch of line breaks there?

Amado last year

Just to visualize all the text in one screen. Besides, it is easier to copy/paste in this way

Amado last year

What do you think? Should I try with an earlier version of traccar or mysql?

Anton Tananaev last year

Line breaks probably made it invalid, so you should fix that.

Amado last year

Yessss, that fixes the problem. Thank you Anton!!!!