Configuring UTF8 Character Set for MySQL
To create a MySQL database which uses the UTF-8 character set:
Create a new database:
create database <database_name> character set utf8mb4 collate utf8mb4_binOpen
<TeamCity Data Directory>
/config/database.properties
and add thecharacterEncoding
property:connectionProperties.characterEncoding=UTF-8
To change the character set of an existing MySQL database to UTF-8:
Shut down the TeamCity server.
From the
<TeamCity Home>
/bin
directory, export the database using the maintainDB tool:maintainDB backup -D -F database_backupMore details on the backup procedure are here.
Create a new database with UTF-8 as the default character set, as described in Step 1.
Modify the
<TeamCity Data Directory>
/config/database.properties
file by changing theconnectionUrl
property to:jdbc:mysql://<host>/<new_database_name>Import data to the new database:
maintainDB restore -D -F database_backup -T <TeamCity Data Directory>/config/database.propertiesStart the TeamCity server.
Last modified: 24 September 2024