You are viewing the documentation of TeamCity 8.x, which is not the most recently released version of TeamCity.
View this page in TeamCity 9.x documentation or refer to the listing to choose the documentation corresponding to your TeamCity version.
Skip to end of metadata
Go to start of metadata

To create a MySQL database which uses the utf8 character set:

  1. Create a new database:
    create database <database_name> character set UTF8 collate utf8_bin
    
  2. Open <TeamCity data directory>/config/database.properties, and add the characterEncoding property:
    connectionProperties.characterEncoding=UTF-8
    

To change the character set of an existing MySQL database to utf8:

  1. Shut the TeamCity server down.
  2. Being in the TeamCity bin directory, export the database using the maintainDB tool:
    maintainDB backup -D -F database_backup
    

    (more details about backup are here)

  3. Create a new database with utf8 as the default character set, as described above.
  4. Modify the <TeamCity data directory>/config/database.properties file --- change connectionUrl property to:
  5. jdbc:mysql://<host>/<new_database_name>
    
  6. Import data the new database:
    maintainDB restore -D -F database_backup -T <TeamCity data directory>/config/database.properties
    
  7. Start the TeamCity server up
Labels:
server server Delete
configure configure Delete
utf utf Delete
admin admin Delete
mysql mysql Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. Apr 16, 2012

    Open <TeamCity data directory>/config/database.properties, and add the characterEncoding property:

    Maybe filename should be database.<db_type_here>.properties, isn't it?

    1. Apr 26, 2012

      No it shouldn't.