The Sonarqube software is installed as a service on an AWS EC2 Windows instance. The service will no long start and run so we don’t have access to the appllication. The windows service starts and changes immediately into the “Paused” state. A window pops up saying that the service did not start and there is no return code. Rebooting there server changes nothing. Manually starting the service has the same result. Stopping and Starting the service has the same result. The nginx service is running and accessible but the sonarqube services will not run. This is evident both by looking at the Windows “Services” control panel and also by looking at Windows Resource Monitor and not seeing a sonarqube process and nothing running on port 9000. Hopefully this helps point to the type of help we need.
Hey there.
I get this from the SonarServiceWrapper log…
2025-06-17 16:50:22,427 INFO - Starting service 'SonarQube (SonarQube)'...
2025-06-17 16:50:22,433 FATAL - Cannot start service SonarQube on computer '.'.
I get this from sonar log -
2025.06.17 16:48:58 INFO app[][o.s.a.es.EsSettings] Elasticsearch listening on [HTTP: 127.0.0.1:9001, TCP: 127.0.0.1:56881]
2025.06.17 16:48:58 INFO app[][o.s.a.ProcessLauncherImpl] Launch process[ELASTICSEARCH] from [C:\Program Files\SonarQube\elasticsearch]: C:\Program Files\Java\jdk-17\bin\java -Xms4m -Xmx64m -XX:+UseSerialGC -Dcli.name=server -Dcli.script=./bin/elasticsearch -Dcli.libs=lib/tools/server-cli -Des.path.home=C:\Program Files\SonarQube\elasticsearch -Des.path.conf=C:\Program Files\SonarQube\temp\conf\es -Des.distribution.type=tar -cp C:\Program Files\SonarQube\elasticsearch\lib\*;C:\Program Files\SonarQube\elasticsearch\lib\cli-launcher\* org.elasticsearch.launcher.CliToolLauncher
2025.06.17 16:48:58 INFO app[][o.s.a.SchedulerImpl] Waiting for Elasticsearch to be up and running
2025.06.17 16:49:17 INFO app[][o.s.a.SchedulerImpl] Process[es] is up
2025.06.17 16:49:17 INFO app[][o.s.a.ProcessLauncherImpl] Launch process[WEB_SERVER] from [C:\Program Files\SonarQube]: C:\Program Files\Java\jdk-17\bin\java -Djava.awt.headless=true -Dfile.encoding=UTF-8 -Djava.io.tmpdir=C:\Program Files\SonarQube\temp -XX:-OmitStackTraceInFastThrow --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED --add-exports=java.base/jdk.internal.ref=ALL-UNNAMED --add-opens=java.base/java.nio=ALL-UNNAMED --add-opens=java.base/sun.nio.ch=ALL-UNNAMED --add-opens=java.management/sun.management=ALL-UNNAMED --add-opens=jdk.management/com.sun.management.internal=ALL-UNNAMED -Xmx512m -Xms128m -XX:+HeapDumpOnOutOfMemoryError -Dhttp.nonProxyHosts=localhost|127.*|[::1] -cp ./lib/sonar-application-10.6.0.92116.jar;C:\Program Files\SonarQube\lib\jdbc\mssql\mssql-jdbc-12.6.1.jre11.jar org.sonar.server.app.WebServer C:\Program Files\SonarQube\temp\sq-process14975158218276474325properties
2025.06.17 16:49:23 INFO app[][o.s.a.SchedulerImpl] Process[Web Server] is stopped
2025.06.17 16:49:23 INFO app[][o.s.a.SchedulerImpl] Process[ElasticSearch] is stopped
2025.06.17 16:49:23 INFO app[][o.s.a.SchedulerImpl] SonarQube is stopped
I found this at the end of the web log and seems to be the culprit -
2025.06.17 16:49:22 INFO web[][c.z.h.HikariDataSource] HikariPool-1 - Shutdown initiated...
2025.06.17 16:49:23 INFO web[][c.z.h.HikariDataSource] HikariPool-1 - Shutdown completed.
2025.06.17 16:49:23 INFO web[][o.s.p.ProcessEntryPoint] Hard stopping process
To my knowledge no one has upgraded anything on the application.
Thank you for your help
Richard
The last log didn’t come through correctly
2025.06.17 16:49:22 INFO web[][c.z.h.HikariDataSource] HikariPool-1 - Shutdown initiated...
2025.06.17 16:49:23 INFO web[][c.z.h.HikariDataSource] HikariPool-1 - Shutdown completed.
2025.06.17 16:49:23 INFO web[][o.s.p.ProcessEntryPoint] Hard stopping process
Caused by: org.sonar.api.utils.MessageException: Database was upgraded to a more recent version of SonarQube. A backup must probably be restored or the DB settings are incorrect.
Caused by: org.sonar.api.utils.MessageException: Database was upgraded to a more recent version of SonarQube. A backup must probably be restored or the DB settings are incorrect.
What version of SonarQube are you trying to start up?
Is there a way to tell what version is installed by looking at some files on the system since I can’t get the application to come up?
In the lib directory you should see a file like sonar-application-2025.1.2.108896.jar
That version string (after sonar-application) is the version.
10.6.0.92116
The error message indeed indicates that your SonarQube database has been upgraded to a newer version. This does not happen automatically—it could, for example, occur if someone else (possibly on a different EC2 instance) connected to the database and upgraded it.
You have a few options here:
-
Check Database Connections: Ensure that multiple SonarQube instances haven’t been installed on the same database server, and verify that your JDBC configuration (
sonar.jdbc.url
) points to the correct schema. -
Restore from Backup: If an upgrade occured and you want to revert, you can restore the database from a backup taken before the upgrade (if available).
-
Upgrade SonarQube: Version 10.6 is outdated and no longer an active version. You should be planning to upgrade to version 2025.1 LTA.
You can check to see what version is currently in the database by running SELECT * FROM schema_migrations;
You should see values like 2025_01_000
if your database was upgraded to v2025.1. You would see values like 10_6_000
but no higher (10_7_000) if the database was indeed at v10.6.