We are moving from MySQL on AWS RDS to MariaDB on-premise. To do so without downtime, we planned to create a replication first between the MySQL master and the MariaDB slave and then promote the MariaDB slave to become the new master.
MySQL on AWS RDS is 8.0.28 MariaDB on our servers is 10.6
The default MySQL collation is utf8mb4_0900_ai_ci
, which MariaDB does not support. So we did:
- We converted all tables to
utf8mb4_unicode_ci
(some wereutf8_unicode_ci
, we kept them that way) - Via AWS Parameter Store, we changed the variables
collation_connection
,collation_server
,default_collation_for_utf8mb4
toutf8mb4_general_ci
. These changes are reflected when runningshow global VARIABLES like '%collat%'
Only collation_database
remains utf8mb4_0900_ai_ci
, AWS doesn't allow to modify it.
Importing the dump from MySQL to MariaDB is running without any issues.
But once we start the replication, it immediately fails with
Error ‘Character set ‘#255’ is not a compiled character set and is not specified in the ‘/usr/share/mysql/charsets/Index.xml’ file’ on query. Default database: ‘’. Query: ‘BEGIN’
How can we make this replication work?
Thank you very much