Template for a good bug report, formatted with Markdown:
versions used (SonarQube, Scanner, Plugin, and any relevant extension)
Sonarqube 4.5.7
Sonarqube 5.6.7
error observed (wrap logs/code around triple quote ``` for proper formatting)
The webserver cannot start and the DB migration can’t be completed.
Log attached.
steps to reproduce
Installed 4.5.7 successfully.
Trying to upgrade to 5.6.7.access.txt (151.0 KB) sonar.txt (18.1 KB)
potential workaround
P.S.: use the #bug:fault sub-category if you’re hitting a specific crash/error , or the #bug:fp sub-category for rules-related behaviour
Just to check, you aren’t installing a fresh v4.5.7 instance, right? It’s a little unclear from your steps to reproduce.
If not, it’s cool that you’re upgrading! Hope you plan on making it all the way from v4.5.7 to the current LTS (6.7) or latest version (7.7)
Based on the logs, I would check and make sure your former SonarQube Service is fully stopped, specifically make sure you have no lingering java processes that maybe didn’t stop all the way.
I’d also give a read to all the Upgrade Notes between v4.5.7 and v5.6. I’ve never actually handled an upgrade between these versions (4.5 was initially released in September 2014), so, unfortunately, I don’t have a lot of common “gotchas” to share.
I would, however, try and browse to the /setup URL it suggests. Maybe in days of SonarQube past, the web server isn’t considered “started” until the database migration has finished.
Sorry to jump in middle of the post but we are also facing an issue with upgrade from 4.5.7 to 5.6.7 with below error. We are on PostgreSQL 9.5 and want to go all the way to latest. Any help is appreciated
2019.05.27 18:57:10 INFO web[DbMigration] == RenameIssueLongDates: migrating ===========================================
2019.05.27 18:57:10 INFO web[DbMigration] – remove_index(“issues”, {:name=>“issues_updated_at”})
2019.05.27 18:57:12 TRACE web[sql] time=1376ms | sql=DROP INDEX issues_updated_at
2019.05.27 18:57:12 INFO web[DbMigration] -> 1.3780s
2019.05.27 18:57:12 INFO web[DbMigration] -> 0 rows
2019.05.27 18:57:12 INFO web[DbMigration] – columns(“issues”)
2019.05.27 18:57:12 INFO web[DbMigration] -> 0.1340s
2019.05.27 18:57:12 INFO web[DbMigration] – remove_column(“issues”, “created_at”)
2019.05.27 18:57:12 TRACE web[sql] time=133ms | sql=ALTER TABLE “issues” DROP “created_at”
2019.05.27 18:57:12 INFO web[DbMigration] -> 0.1360s
2019.05.27 18:57:12 INFO web[DbMigration] – columns(“issues”) 2019.05.27 18:57:12 TRACE web[sql] time=1ms | sql=select 1
2019.05.27 18:57:12 INFO web[o.s.s.d.m.PlatformDatabaseMigration] DB migration failed | time=2088815ms
2019.05.27 18:57:12 ERROR web[o.s.s.d.m.PlatformDatabaseMigration] DB Migration or container restart failed. Process ended with an exception
org.jruby.exceptions.RaiseException: (StandardError) An error has occurred, all later migrations canceled:
No message available
2019.05.27 18:57:13 TRACE web[sql] time=0ms | sql=select version from schema_migrations