Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,456,044
Community Members
 
Community Events
176
Community Groups

Failing to install Crowd on PostgreSQL 9.6

Edited

I'm trying to install Crowd with a PostgreSQL but running always into the same issue. While the database tables are created I get the following error:

 

INFO http-nio-8095-exec-11 INFO [liquibase] ChangeSet liquibase/bootstrap/22_cwd_synchronisation_status.xml::KRAK-707: cwd_synchronisation_status::crowd ran successfully in 59ms
ERROR http-nio-8095-exec-11 ERROR [liquibase] Change Set liquibase/bootstrap/22_cwd_synchronisation_status.xml::KRAK-707: cwd_synchronisation_status - name foreign key::crowd failed. Error: ERROR: constraint "fk_clce0lxxnu12qkiwf3xu5iody" of relation "cwd_synchronisation_status" does not exist
Location: File: tablecmds.c, Routine: ATExecDropConstraint, Line: 7805
Server SQLState: 42704 [Failed SQL: ALTER TABLE crowd.cwd_synchronisation_status DROP CONSTRAINT fk_clce0lxxnu12qkiwf3xu5iody]
INFO http-nio-8095-exec-11 INFO [liquibase] Successfully released change log lock
ERROR http-nio-8095-exec-11 ERROR [console.action.setup.Database] Database configuration failed. liquibase.exception.MigrationFailedException: Migration failed for change set liquibase/bootstrap/22_cwd_synchronisation_status.xml::KRAK-707: cwd_synchronisation_status - name foreign key::crowd:
Reason: liquibase.exception.DatabaseException: ERROR: constraint "fk_clce0lxxnu12qkiwf3xu5iody" of relation "cwd_synchronisation_status" does not exist
Location: File: tablecmds.c, Routine: ATExecDropConstraint, Line: 7805
Server SQLState: 42704 [Failed SQL: ALTER TABLE crowd.cwd_synchronisation_status DROP CONSTRAINT fk_clce0lxxnu12qkiwf3xu5iody]
java.lang.RuntimeException: liquibase.exception.MigrationFailedException: Migration failed for change set liquibase/bootstrap/22_cwd_synchronisation_status.xml::KRAK-707: cwd_synchronisation_status - name foreign key::crowd:
Reason: liquibase.exception.DatabaseException: ERROR: constraint "fk_clce0lxxnu12qkiwf3xu5iody" of relation "cwd_synchronisation_status" does not exist
Location: File: tablecmds.c, Routine: ATExecDropConstraint, Line: 7805
Server SQLState: 42704 [Failed SQL: ALTER TABLE crowd.cwd_synchronisation_status DROP CONSTRAINT fk_clce0lxxnu12qkiwf3xu5iody]
at com.atlassian.crowd.util.persistence.hibernate.LiquibaseSchemaHelper.runLiquibaseUpdate(LiquibaseSchemaHelper.java:142)
at com.atlassian.crowd.util.persistence.hibernate.LiquibaseSchemaHelper.lambda$updateSchemaIfNeeded$1(LiquibaseSchemaHelper.java:80)
at com.atlassian.crowd.util.persistence.hibernate.LiquibaseSchemaHelper.withServiceRegistry(LiquibaseSchemaHelper.java:166)
at com.atlassian.crowd.util.persistence.hibernate.LiquibaseSchemaHelper.withServiceRegistry(LiquibaseSchemaHelper.java:152)

 

Here is what I tried:

  • Multiple times with fresh installations of both Crowd and the DB
  • Crowd 3.4.3 and 3.4.4
  • PostgreSQL 10 and 9.6.
  • PostgreSQL Dialects: PostgreSQL94Dialect, PostgreSQL9Dialect and PostgreSQLDialect
  • Using a seperate crowd schema and the public schema

1 answer

1 accepted

I finally found the answer:

Atlassian tools do not officially support using schemas in PostgreSQL and while you can circumvent this by adding "?currentSchema=yourschema" to the end of the JDBC connection string (or if you do not have a connection string to the end of the database name) and all tools will install in the schemas you give them, there seems to still be some black magic going on.

My initial though process was that Crowd really does not like installing in a separate schema but even an installation to the standard public schema failed with the same issues.

Turns out that I installed Jira and Confluence beforehand in their respective schemas and naivly thought that this would not affect installations in other schemas but it actually caused problems with both Bitbucket and Crowd (different SQL issues but ultimately failed installations).

The only installation order I found that works and does not fail on the database setup stage for all tools:

  1. Bitbucket
  2. Crowd
  3. Jira
  4. Confluence
  5. Bamboo

I'm still a bit on the fence about Jira and Bamboo because while installation did succeed and I have not yet seen any apparent visible issues I do sometimes see errors related to missing relations in the logs.

Suggest an answer

Log in or Sign up to answer
TAGS

Atlassian Community Events