java.net.ConnectException: Connection refused

Jenkins JIRA | Sylvie Carrier | 11 months ago
  1. 0

    Building a "Maven project" in a Docker container fails with a "connection refused" error message whereas the same build is successful in a "Freestyle project" (also build in a Docker container plugin). [ael.validate-in-docker-mvnproject] $ docker exec --tty --user 500: dc69be1aed975dbff977348d060329d75d1377ecbefaf929a269a11fc5e40373 env ANT_HOME=/opt/apache-ant-1.8.2 CLASSPATH= EXECUTOR_NUMBER=0 JAVA_HOME=/opt/jdk1.7.0_45 JENKINS_HOME=/data/EDT/jenkins M2_HOME=/opt/apache-maven-3.0.4 MAVEN_HOME=/opt/apache-maven-3.0.4 "MAVEN_OPTS=-Xms1g -Xmx1g -XX:MaxPermSize=256m -Dfile.encoding=Cp1252" no_proxy=/var/run/docker.sock ORACLE_HOME=/opt/oracle11/product/11.2.0/client/ PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/jdk1.7.0_45/bin:/opt/apache-ant-1.8.2/bin:/opt/apache-maven-3.0.4/bin TERM=xterm WORKSPACE=/data/EDT/jenkinsSlave_recette_1/c3f621fe/workspace/ael.validate-in-docker-mvnproject java -cp /data/EDT/jenkinsSlave_recette_1/c3f621fe/maven3-agent.jar:/opt/apache-maven-3.0.4/boot/plexus-classworlds-2.4.jar org.jvnet.hudson.maven3.agent.Maven3Main /opt/apache-maven-3.0.4 /data/EDT/jenkinsSlave_recette_1/slave.jar /data/EDT/jenkinsSlave_recette_1/c3f621fe/maven3-interceptor.jar /data/EDT/jenkinsSlave_recette_1/c3f621fe/maven3-interceptor-commons.jar 44848 Exception in thread "main" java.net.ConnectException: Connection refused at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339) at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200) at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) at java.net.Socket.connect(Socket.java:579) at java.net.Socket.connect(Socket.java:528) at java.net.Socket.<init>(Socket.java:425) at java.net.Socket.<init>(Socket.java:208) at org.jvnet.hudson.maven3.agent.Maven3Main.main(Maven3Main.java:136) at org.jvnet.hudson.maven3.agent.Maven3Main.main(Maven3Main.java:70) Stopping Docker container after build completion

    Jenkins JIRA | 11 months ago | Sylvie Carrier
    java.net.ConnectException: Connection refused
  2. 0

    Building a "Maven project" in a Docker container fails with a "connection refused" error message whereas the same build is successful in a "Freestyle project" (also build in a Docker container plugin). [ael.validate-in-docker-mvnproject] $ docker exec --tty --user 500: dc69be1aed975dbff977348d060329d75d1377ecbefaf929a269a11fc5e40373 env ANT_HOME=/opt/apache-ant-1.8.2 CLASSPATH= EXECUTOR_NUMBER=0 JAVA_HOME=/opt/jdk1.7.0_45 JENKINS_HOME=/data/EDT/jenkins M2_HOME=/opt/apache-maven-3.0.4 MAVEN_HOME=/opt/apache-maven-3.0.4 "MAVEN_OPTS=-Xms1g -Xmx1g -XX:MaxPermSize=256m -Dfile.encoding=Cp1252" no_proxy=/var/run/docker.sock ORACLE_HOME=/opt/oracle11/product/11.2.0/client/ PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/jdk1.7.0_45/bin:/opt/apache-ant-1.8.2/bin:/opt/apache-maven-3.0.4/bin TERM=xterm WORKSPACE=/data/EDT/jenkinsSlave_recette_1/c3f621fe/workspace/ael.validate-in-docker-mvnproject java -cp /data/EDT/jenkinsSlave_recette_1/c3f621fe/maven3-agent.jar:/opt/apache-maven-3.0.4/boot/plexus-classworlds-2.4.jar org.jvnet.hudson.maven3.agent.Maven3Main /opt/apache-maven-3.0.4 /data/EDT/jenkinsSlave_recette_1/slave.jar /data/EDT/jenkinsSlave_recette_1/c3f621fe/maven3-interceptor.jar /data/EDT/jenkinsSlave_recette_1/c3f621fe/maven3-interceptor-commons.jar 44848 Exception in thread "main" java.net.ConnectException: Connection refused at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339) at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200) at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) at java.net.Socket.connect(Socket.java:579) at java.net.Socket.connect(Socket.java:528) at java.net.Socket.<init>(Socket.java:425) at java.net.Socket.<init>(Socket.java:208) at org.jvnet.hudson.maven3.agent.Maven3Main.main(Maven3Main.java:136) at org.jvnet.hudson.maven3.agent.Maven3Main.main(Maven3Main.java:70) Stopping Docker container after build completion

    Jenkins JIRA | 11 months ago | Sylvie Carrier
    java.net.ConnectException: Connection refused
  3. Speed up your debug routine!

    Automated exception search integrated into your IDE

  4. 0

    Connection refused exception with maven3

    Google Groups | 6 years ago | Steffen Stundzig
    java.net.ConnectException: Connection refused
  5. 0

    irods server disappears,causes hang in idrop

    GitHub | 2 years ago | michael-conway
    java.net.ConnectException: Connection refused

  1. michallos 1 times, last 7 days ago
  2. treefolk 2 times, last 3 days ago
  3. linxiaolong 18 times, last 4 weeks ago
  4. Kialandei 1 times, last 1 month ago
  5. DoktorDoener666 41 times, last 3 weeks ago
24 more registered users
65 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.net.ConnectException

    Connection refused

    at java.net.PlainSocketImpl.socketConnect()
  2. Java RT
    Socket.<init>
    1. java.net.PlainSocketImpl.socketConnect(Native Method)
    2. java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)
    3. java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200)
    4. java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182)
    5. java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
    6. java.net.Socket.connect(Socket.java:579)
    7. java.net.Socket.connect(Socket.java:528)
    8. java.net.Socket.<init>(Socket.java:425)
    9. java.net.Socket.<init>(Socket.java:208)
    9 frames
  3. M3 Agent
    Maven3Main.main
    1. org.jvnet.hudson.maven3.agent.Maven3Main.main(Maven3Main.java:136)
    2. org.jvnet.hudson.maven3.agent.Maven3Main.main(Maven3Main.java:70)
    2 frames