ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Rosjava install problem ./gradlew install

asked 2012-09-10 06:27:52 -0500

LargeBearCat gravatar image

Hi, I am trying to install ROSJava (Fuerte). I have already installed the regular ROS (Fuerte). I am working through the rosjava building steps (

When I get to ./gradlew install it shows a lot of Java errors:


Exception in thread "main" Connection refused at Method) at at at at at at at at at at<init>( at at at at at at at org.gradle.wrapper.Download.downloadInternal( at at org.gradle.wrapper.Install.createDist( at org.gradle.wrapper.WrapperExecutor.execute( at org.gradle.wrapper.GradleWrapperMain.main(

I have installed the Oracle Java JDK, set JAVA_HOME with PATH="....:$JAVA_HOME/bin", Mercurial and Maven.


edit retag flag offensive close merge delete

4 Answers

Sort by ยป oldest newest most voted

answered 2012-09-11 02:27:47 -0500

KruseT gravatar image

Gradle needs an internet connection. Gradle tries to donwnload that file, but got a connection error. You can also try manually:


if that works, the gradle command should also work.

edit flag offensive delete link more

answered 2012-10-05 20:35:50 -0500

Jalan gravatar image

updated 2012-10-06 06:03:52 -0500


How did you solve the problem? I am still stuck with same problem as yours. How did you specify proxy settings for gradle?

I am using Ubuntu 12.04 and ROS Fuerte.

Thanks a lot in advance. :)

EDIT: Hey, Sorry for the trouble. I figured out finally. :)

You just have to add this to your ~/.bashrc or ~/.zshrc configuration file:

export JAVA_OPTS='-Dhttp.proxyHost=proxyhostURL -Dhttp.proxyPort=proxyPortNumber -Dhttp.proxyUser=someUserName -Dhttp.proxyPassword=somePassword'

Now it should work flawlessly. :)

Links: [1] [Gradle Installation]( (Refer section: JVM OPTIONS)

edit flag offensive delete link more

answered 2013-06-25 11:22:08 -0500

I solved adding proxy parameters of this way

./gradlew -Dhttp.proxyHost= -Dhttp.proxyPort=8002 clean build

edit flag offensive delete link more

answered 2012-09-12 02:56:46 -0500

LargeBearCat gravatar image

Thanks for the answer.

The solution is even more trivial. Turns out the Ubuntu proxy server settings is not directly used by rosjava.

--> How/Where can I specify proxy settings in rosjava? Could not google it up so far.

edit flag offensive delete link more


Ok, not rosjava proxy settings but gradle proxy settings. The download has now started, hope no more new errors.

LargeBearCat gravatar image LargeBearCat  ( 2012-09-12 03:10:06 -0500 )edit

Question Tools

1 follower


Asked: 2012-09-10 06:27:52 -0500

Seen: 1,647 times

Last updated: Jun 25 '13