How to provide Sonar Runner home path to sonar4bamboo

I installed sonar 4 bamboo on my Bamboo instance (v 5.5.1) and configured Sonar server settings from the administration pane.

I created a SonarQube Runner task in my plan which required to create a new Executable capability in order to define sonar runner home (I specified a path on the network that can be reached by all bamboo agents).

Unfortunately, my plan is failing because sonar runner can not be found by the plugin. The problem is that it seems the path provided in the capability is not taken into account : 

Unable to find executable at C:\Users\xxxxx\bamboo-agent-home\bin\bin\sonar-runner.bat. Will try to run it anyway.
The system cannot find the path specified.

I tried to use a local path instead of network one but it doesn't work any better.

Is there anything i'm doing wrong ?

5 answers

0 votes

Hello Nicolas,

Thank you for your question.

Please, make sure you are specifying the correct location to Sonar executable.


Based on the path above, please notice there are two "bin" directories and, in my opinion, it is not intended to be like that. Please, notice this will vary depending on the installation directory given.

If you find this answer useful, I would kindly ask you to accept it so the same will be visible to others who might be facing the same issue you have inquired.

Thank you for your understanding.

Kind regards,
Rafael P. Sperafico
Atlassian Support


Hello Rafael and thanks for your answer.

Actually, I never provided a path like this to sonar 4 bamboo.

I tried a network path (like "\\my_server\my_shared_folder\folder\[...]\SonarRunner2.4\") and a local path (like "d:\SonarRunner2.4\"). Actually, whatever path I specify, I always get the same error about path "C:\Users\xxxxx\bamboo-agent-home\bin\bin\sonar-runner.bat" which makes me think that the path I provide is not taken into account at all.

What do you think ?




Hello Nicolas, * could you please inform what is the correct location to "sonar-runner.bat", please? * could you please add an Script task to your plan with the following: # on Windows, please uncomment the following line by removing the hash (#) #env # on Linux, please uncomment the following line by removing the hash (#) #set * could you please inform what is the Sonar add-on you have installed in Bamboo? Could you provide me with an screenshot displaying it in Manage Add-ons in Bamboo, please? The above will display all the environment variable available to Bamboo — Kind regards, Rafael P. Sperafico Atlassian Support

Hi Nicolas,

I'm the author of the Sonar for Bamboo add-on. Actually I can only think of a Windows issue here. I've just created a new SonarRunner based Bamboo build by defining the home of the SonarRunner directory in the capabilities section (/opt/sonar/sonar-runner-2.4 in my example).

I'll try to setup a Bamboo instance on Windows to reproduce this and reply to this thread as soon as I have a solution.



Hello Michael, Pleasure talking to you. I am looking forward to hearing from you. — Kind regards, Rafael P. Sperafico Atlassian Support


Just wanted to keep you up-to-date about the progress on this. We plan to auto-discover SonarRunner installations based on the SONAR_RUNNER_HOME environment variable in the future. This would make a manual definition of the path obsolete. You can track the progress of this here:

Concerning your issue with SonarRunner on Windows: Would you mind to create a bug report at I think it is better when we discuss this issue there instead on this thread.

Thanks for bringing this up.

Michael from Mibex Software

Thanks for your followup. I just created the bug in your backlog : Regards, Nicolas

As an administrator, you could define a new executable under ‘Overview —> Server capabilities —> Add capability’...

 Capability type: Executable

 Type: Sonar Runner Home

 Executable label: sonarrunner


Suggest an answer

Log in or Sign up to answer
Community showcase
Published 4 hours ago in Statuspage

194 years of downtime: looking back on incident data from 2018

Statuspage customers logged more than 194 years of collective incidents in 2018. That’s a whopping 87% increase from the  104 years logged in 2017 , and we aren’t even through December yet....

15 views 0 3
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you