New Bamboo installation fails at admin creation screen with: Failed to retrieve or create group: bamboo-admin
Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.
Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Problem
New Bamboo installation fails at the admin creation screen and the following error appears in the user interface and <bamboo-home>/logs/atlassian-bamboo.log
com.atlassian.core.exception.InfrastructureException: Failed to retrieve or create group: bamboo-admin
at bucket.user.DefaultUserAccessor.getGroupCreateIfNecessary(DefaultUserAccessor.java:347)
at bucket.user.DefaultUserAccessor.addUser(DefaultUserAccessor.java:80)
...
Caused by: org.springframework.dao.InvalidDataAccessResourceUsageException: could not extract ResultSet; SQL [n/a]; nested exception is org.hibernate.exception.SQLGrammarException: could not extract ResultSet
at org.springframework.orm.hibernate5.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:230)
...
Caused by: org.hibernate.exception.SQLGrammarException: could not extract ResultSet
at org.hibernate.exception.internal.SQLExceptionTypeDelegate.convert(SQLExceptionTypeDelegate.java:63)
at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:42)
at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:111)
...
Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'GROUPS defaulthib0_ where defaulthib0_.GROUPNAME='bamboo-admin'' at line 1
at sun.reflect.GeneratedConstructorAccessor55.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:425)
...
Diagnosis
Environment
- MySQL Version 8 and Bamboo 6 or 7
Cause
In MySQL 8, GROUPS is a reserved keyword however Bamboo has a table that shares the same name.
Resolution
Create a new Bamboo database on a supported version of MySQL and perform the installation again.
At the time of the initial writing of this KB back in 2018, Bamboo's current version (6.5.0) did not support MySQL 8. MySQL 5.7 was the latest supported version.
From Bamboo 8.0, MySQL 8 is now fully supported. The supported version of MySQL for each version of Bamboo can be found in the below documentation: