Comment 7 for bug 1575688

Revision history for this message
Mitchell Zubarev-Foxworth (mitch-foxworth) wrote : Re: Mitaka on 16.04 Xenial and mysql's new default utf8mb4 charset

Confirmed @namgon's fix (this is building Openstack Liberty on 16.04; I was seeing the problem populating the keystone database):

1) Replace all instances of 'utf8mb4' with 'utf8' in /etc/mysql/mariadb.conf.d/*

2) Add the below to /etc/mysql/conf.d/mysqld_openstack.cnf:
[client]
default-character-set = utf8

[mysqld]
bind-address = 172.16.3.32
default-storage-engine = innodb
innodb_file_per_table
collation-server = utf8_general_ci
init-connect = 'SET NAMES utf8'
character-set-server = utf8

[mysql]
default-character-set = utf8

3) Drop the keystone database
4) Restart mysql service
5) Run 'keystone-manage db_sync'

For some reason I was still getting the error when /etc/mysql/conf.d/mysqld_openstack.cnf had the above values, and modifying the files in /etc/mysql/mariadb.conf.d/ was also necessary to fix.