I was just trying to use a postgres DB as I’d been using the H2 for a couple of weeks. I don’t need any data from the H2. So I set up Postgres 10 and ran it, but using Postgres it fails. The first time I ran it the logs just died half way through migration. The next time i started the service it came back with
org.sonar.server.platform.db.migration.step.MigrationStepExecutionException: Execution of migration step #2703 ‘Add security fields to Elasticsearch indices’ failed
Caused by: org.elasticsearch.cluster.block.ClusterBlockException: blocked by: [FORBIDDEN/12/index read-only / allow delete (api)];
If I try to start the service again from the command line I get that SonarQube is under maintenance.
I don’t have a backup for Postgres as it’s a fresh install, but I ran VACCUM FULL anyway on the sonar DB. I then “upgraded” and I got
Upgrade Failed
Database connection cannot be established. Please check database status and JDBC settings.
I know these connections are right as the database has been connected to and made its way through half the migration.
So I’m not really sure what’s going on here