Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

  1. ,
    Expert tip

    Check if your firewall is not blocking your connection. If it's not, you might need to explicitly set advertised.host.name to advertised.host.name = yourIpAddress, this forces the hosts returned to be the resolvable IP address of your VM.

Solutions on the web

via Google Groups by geraldo netto, 4 months ago
via Apache's JIRA Issue Tracker by Michael Han, 1 year ago
via Google Groups by Unknown author, 11 months ago
via Stack Overflow by ARAZ
, 1 year ago
java.net.ConnectException: Connection refused	at sun.nio.ch.Net.connect0(Native Method)	at sun.nio.ch.Net.connect(Net.java:465)	at sun.nio.ch.Net.connect(Net.java:457)	at sun.nio.ch.SocketChannelImpl.connect(SocketChannelImpl.java:670)	at org.apache.zookeeper.ClientCnxnSocketNIO.registerAndConnect(ClientCnxnSocketNIO.java:275)	at org.apache.zookeeper.ClientCnxnSocketNIO.connect(ClientCnxnSocketNIO.java:285)	at org.apache.zookeeper.ClientCnxn$SendThread.startConnect(ClientCnxn.java:1098)	at org.apache.zookeeper.ClientCnxn$SendThread.run(ClientCnxn.java:1133)