Unsuccessful Sonar Launch

I have a sonar instance that runs on my local machine on localhost: 9000, and I can go and use the console. When I try to run sonar-runner from the command line for the project, I get a 500 error:

Exception in thread "main" org.sonar.runner.RunnerException: org.picocontainer.PicoLifecycleException: PicoLifecycleException: method 'public void org.sonar.batch.bootstrap.DatabaseCompatibility.start()', instance ' org.sonar.batch.bootstrap.DatabaseCompatibility@3848110b , org.sonar.api.utils.HttpDownloader$HttpException: Fail to download [http://localhost:9000/api/server]. Response code: 500 at org.sonar.runner.Runner.delegateExecution(Runner.java:288) at org.sonar.runner.Runner.execute(Runner.java:151) at org.sonar.runner.Main.execute(Main.java:84) at org.sonar.runner.Main.main(Main.java:56) Caused by: org.picocontainer.PicoLifecycleException: PicoLifecycleException: method 'public void org.sonar.batch.bootstrap.DatabaseCompatibility.start()', instance ' org.sonar.batch.bootstrap.DatabaseCompatibility@3848110b , org.sonar.api.utils.HttpDownloader$HttpException: Fail to download [http://localhost:9000/api/server]. Response code: 500 at org.picocontainer.monitors.NullComponentMonitor.lifecycleInvocationFailed(NullComponentMonitor.java:77) ... ... 

But when I find the url in my browser, I get the following xml response:

 <server> <id>20131007131041</id> <version>3.4.1</version> <status>UP</status> </server> 

I'm not sure where to go from here. Any tips?

+7
sonarqube sonar-runner
source share
2 answers

The current workaround is to disable the GEM_PATH and GEM_HOME before starting the sonar web service:

 unset GEM_PATH GEM_HOME ./sonar.sh console 

This does not need to be done for sonar environments.

The problem is caused by a conflict with the local Ruby installation .

+4
source share

According to the sonar documentation, you need to create sonar-project.properties in the root of your project, and then run sonar-runner from the command line

ref Sonar Documents for Runners

In my case, it worked with the following workaround

1: export GEM_HOME=''

2: export GEM_PATH=''

3: restart the sonar web server

4: run sonar-runner on the project path

+1
source share

All Articles