java.net.ConnectException

Connection refused * at java.net.PlainSocketImpl.socketConnect(Native Method)

Samebug tips9

Check if your MongoDB is available.


Check if your server (or a proxy server) is not going up and down. There might be something between a proxy and a client sending intermittent requests to non-functioning hosts as well. There might as well be too many requests in a short amount of time.

Don't give up yet. Our experts can help. Paste your full stack trace to get a solution.

Solutions on the web13331

  • via Google Groups by larry13767, 1 year ago
    Connection refused [testng] at java.net.PlainSocketImpl.socketConnect(Native Method)
  • via daisy.org by Unknown author, 1 year ago
    Connection refused at java.net.PlainSocketImpl.socketConnect(Native Method)
  • via Oracle Community by 843793, 2 weeks ago
    Connection refused at java.net.PlainSocketImpl.socketConnect<Native Method>
  • Stack trace

    • java.net.ConnectException: Connection refused * at java.net.PlainSocketImpl.socketConnect(Native Method) at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333) at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195) at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182) at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366) at java.net.Socket.connect(Socket.java:519)

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    13 times, 12 hours ago
    47 times, 14 hours ago
    17 times, 17 hours ago
    Once, 2 days ago
    7 times, 2 days ago
    391 more bugmates