Sonarqube Community Build 9.9 failing to start

I have configured sonarqube Community Build 9.9 on my server
JAVA version is 17
I have directly configured sonarqube from zip file

Initially sonarqube server was running perfectly, but later it stopped and and now when I am trying to restart it then its erroring while starting elasticserach

In logs its generating only two files
sonar.log
nohup.log

Below is the error found in nohup.log file :

2025.06.17 07:30:18 DEBUG app[ ][jdk.event.security] X509Certificate: Alg:SHA1withRSA, Serial:50946cec18ead59c4dd597ef758fa0ad, Subject:CN=XRamp Global Certification Authority, O=XRamp Security Services Inc, OU=www.xrampsecurity.com, C=US, Issuer:CN=XRamp Global Certification Authority, O=XRamp Security Services Inc, OU=www.xrampsecurity.com, C=US, Key type:RSA, Length:2048, Cert Id:-952474086, Valid from:11/1/04, 5:14 PM, Valid until:1/1/35, 5:37 AM
Error: Unable to initialize main class org.elasticsearch.bootstrap.Elasticsearch
Caused by: java.lang.NoClassDefFoundError: joptsimple/OptionSpec
2025.06.17 07:30:18 WARN  app[][o.s.a.p.AbstractManagedProcess] Process exited with exit value [ElasticSearch]: 1
2025.06.17 07:30:18 DEBUG app[][o.s.a.p.ManagedProcessLifecycle] StopWatcher[ElasticSearch] tryToMoveTo ElasticSearch from STARTED to HARD_STOPPING => true
2025.06.17 07:30:18 DEBUG app[][o.s.a.p.ManagedProcessLifecycle] StopWatcher[ElasticSearch] tryToMoveTo ElasticSearch from HARD_STOPPING to FINALIZE_STOPPING => true
2025.06.17 07:30:18 INFO  app[][o.s.a.SchedulerImpl] Process[ElasticSearch] is stopped
2025.06.17 07:30:18 DEBUG app[][o.s.a.p.ManagedProcessLifecycle] StopWatcher[ElasticSearch] tryToMoveTo ElasticSearch from FINALIZE_STOPPING to STOPPED => true
2025.06.17 07:30:18 DEBUG app[][o.s.a.NodeLifecycle] HardStopper-0 tryToMoveTo from STARTING to HARD_STOPPING => true
2025.06.17 07:30:18 DEBUG app[][o.s.a.p.ManagedProcessLifecycle] HardStopper-0 tryToMoveTo Compute Engine from INIT to HARD_STOPPING => false
2025.06.17 07:30:18 DEBUG app[][o.s.a.p.ManagedProcessLifecycle] HardStopper-0 tryToMoveTo Web Server from INIT to HARD_STOPPING => false
2025.06.17 07:30:18 DEBUG app[][o.s.a.p.ManagedProcessLifecycle] HardStopper-0 tryToMoveTo ElasticSearch from STOPPED to HARD_STOPPING => false
2025.06.17 07:30:18 DEBUG app[][o.s.a.NodeLifecycle] HardStopper-0 tryToMoveTo from HARD_STOPPING to FINALIZE_STOPPING => true
2025.06.17 07:30:18 DEBUG app[][o.s.a.NodeLifecycle] HardStopper-0 tryToMoveTo from FINALIZE_STOPPING to STOPPED => true
2025.06.17 07:30:18 INFO  app[][o.s.a.SchedulerImpl] SonarQube is stopped
2025.06.17 07:30:18 DEBUG app[][o.s.a.NodeLifecycle] Shutdown Hook tryToMoveTo from STOPPED to STOPPING => false

Hi,

Welcome to the community!

Only the latest version of SonarQube Community Build is considered active, so you’ll need to update and see if the situation is still replicable before we can help you.

Your update path is:

9.9 → 24.12 → 25.6

You may find these resources helpful:

If you have questions about upgrading, feel free to open a new thread for that here.

Regarding your question, you should probably check your server logs

 
Ann

Hey Ann, thanks for replying
I have downloaded the latest sonarqube (sonarqube-25.6.0.109173), but it is still failing with the same error
Now also two logs files are getting generated
nohub.log
sonar.log

Please check the logs
nohub.log (66.0 KB)
sonar.log (198.9 KB)

Hi,

2025.06.19 06:18:14 DEBUG app[][o.a.h.i.n.c.InternalHttpAsyncClient] [exchange: 1] Request connection for {}->http://localhost:9001
2025.06.19 06:18:14 DEBUG app[][o.a.h.i.n.c.PoolingNHttpClientConnectionManager] Connection request: [route: {}->http://localhost:9001][total kept alive: 0; route allocated: 0 of 10; total allocated: 0 of 30]

Port 9001 is the port we run Elasticsearch on. You should check your es.log.

 
Ann

As I mentioned, its only generating two log files
nohub.log
sonar.log

Its not generating es.log file

Hi,

I think you’re going to have to look outside of SonarQube for this to find what’s preventing the creation of that log. SonarQube won’t run if it can’t write to its logs. You probably have some “helpful” process on the host that (at a guess) suddenly decided to lock down permissions, perhaps in the logs directory, perhaps more broadly.

 
HTH,
Ann

please check these errors i found in nohub.log

Error: Unable to initialize main class org.elasticsearch.bootstrap.Elasticsearch
Caused by: java.lang.NoClassDefFoundError: joptsimple/OptionSpec```

and

2025.06.19 06:18:14 DEBUG app[][o.a.h.i.n.c.MainClientExec] [exchange: 1] start execution
2025.06.19 06:18:14 DEBUG app[][o.a.h.c.p.RequestAddCookies] CookieSpec selected: default
2025.06.19 06:18:14 DEBUG app[][j.io.serialization] Builtin factory: null -> new: null
2025.06.19 06:18:14 DEBUG app[][o.a.h.c.p.RequestAuthCache] Re-using cached 'basic' auth scheme for http://localhost:9001
2025.06.19 06:18:14 DEBUG app[][o.a.h.c.p.RequestAuthCache] No credentials for preemptive authentication
2025.06.19 06:18:14 DEBUG app[][o.a.h.i.n.c.InternalHttpAsyncClient] [exchange: 1] Request connection for {}->http://localhost:9001
2025.06.19 06:18:14 DEBUG app[][o.a.h.i.n.c.PoolingNHttpClientConnectionManager] Connection request: [route: {}->http://localhost:9001][total kept alive: 0; route allocated: 0 of 10; total allocated: 0 of 30]
2025.06.19 06:18:14 DEBUG app[][o.a.h.i.n.c.PoolingNHttpClientConnectionManager] Connection request failed```

Hi,

Please check the other logs found in your nohup.log, E.G.:

2025.06.19 06:18:14 DEBUG app[][o.a.h.i.n.c.PoolingNHttpClientConnectionManager] Connection request failed
java.net.ConnectException: Connection refused
2025.06.19 06:18:14 DEBUG app[][o.a.h.i.n.c.InternalHttpAsyncClient] [exchange: 1] connection request failed
2025.06.19 06:18:14 DEBUG app[][o.e.c.RestClient] request [GET http://localhost:9001/] failed
java.net.ConnectException: Connection refused

Since those come first, I would pay more attention to them.

 
Ann

Its fixed now, it was related to fapolicy rules

1 Like