-
Bug
-
Resolution: Invalid
-
High (View bug fix roadmap)
-
None
-
8.8.0
-
8.08
-
6
-
Severity 2 - Major
-
3
-
Issue Summary
Jira reports incorrectly that MySQL 5.7 database is MySQL 5.6 and won't start Jira when the dbconfig.xml has the database type set to mysql57.
Steps to Reproduce
- Install MySQL 5.7 and set the following.
character_set_client utf8
character_set_connection utf8
character_set_database latin1
character_set_filesystem binary
character_set_results utf8
character_set_server latin1
character_set_system utf8
collation_connection utf8_general_ci
collation_database latin1_swedish_ci
collation_server latin1_swedish_ci
version 5.7.30-0ubuntu0.18.04.1
- In the dbconfig.xml set the database type to mysql57
- Set URL to change the character_endcoding to utf8mb4
- Restart Jira
Expected Results
Jira will start and use the MySQL 5.7 database.
Actual Results
Jira won't start as a result of the default settings. with the URL set with character_endcoding= utf8mb4
2020-04-27 08:39:23,137-0700 JIRA-Bootstrap ERROR [c.a.jira.health.HealthChecks] We've found an error in MySQL supported version! 2020-04-27 08:39:23,137-0700 JIRA-Bootstrap ERROR [c.a.jira.health.HealthChecks] The database type in your dbconfig.xml is set up to MySQl 5.7+ and your MySQL version is 5.6 or lower. Consider using MySQL 5.6 database type instead See our documentation for more information on changing database type. 2020-04-27 08:39:23,137-0700 JIRA-Bootstrap ERROR [c.a.jira.health.HealthChecks] JIRA couldn't connect to your database 2020-04-27 08:39:23,137-0700 JIRA-Bootstrap ERROR [c.a.jira.health.HealthChecks] JIRA failed to establish a connection to your database. This could be because: - Your database isn't running - The configuration of your dbconfig.xml file is incorrect (user, password, or database URL etc.) - There is a network issue between JIRA and your database (e.g. firewall, database doesn't allow remote access etc.) There are several other solutions you can try, review our documentation, and see what works for you.
Old keeping for reference - Workaround
Currently, there is no known workaround.
If you change the dbconfig.xml to use the database type mysql rather than mysql57 Jira starts however you will get a collation warning by the health checker stating utf8mb4 is not a supported collation.
Note on Resolution
- Steps to reproduce are not in sync with Atlassian guidelines how to configure MySql database.
- According to documentation page, https://confluence.atlassian.com/adminjiraserver088/installing-jira-applications/connecting-jira-applications-to-a-database/connecting-jira-applications-to-mysql-5-7 character_set_server variable should be set to utf8mb4,
not latin1 like here.
- According to documentation page, https://confluence.atlassian.com/adminjiraserver088/installing-jira-applications/connecting-jira-applications-to-a-database/connecting-jira-applications-to-mysql-5-7 character_set_server variable should be set to utf8mb4,
- We verified Jira 8.8.0 with MySql 5.7.24 running inside docker and MySql 5.7.30-0ubuntu0.16.04.1 running on Ubuntu using JDBC drivers 8.0.20 and 5.1.48.
There were no problems connecting to and using that database.
https://getsupport.atlassian.com/browse/GHS-241531
Here are all changes we have made to fixed the issue:
How to Fix the Collation and Character Set of a MySQL Database manually