java.net.NoRouteToHostException: No route to host

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

,
Expert tip

Signals that an error occurred while attempting to connect a socket to a remote address and port. Typically, the remote host cannot be reached because of an intervening firewall, or if an intermediate router is down.

Solutions on the web

via GitHub by glamperi
, 7 months ago
No route to host (Host unreachable)
via JDK Bug System by Webbug Group, 1 year ago
No route to host
via Ask Ubuntu by Prateek Manocha
, 5 months ago
No route to host (Host unreachable)
java.net.NoRouteToHostException: No route to host
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at java.net.Socket.connect(Socket.java:538)
at java.net.Socket.(Socket.java:434)
at java.net.Socket.(Socket.java:286)
at org.apache.commons.httpclient.protocol.DefaultProtocolSocketFactory.createSocket(DefaultProtocolSocketFactory.java:80)
at org.apache.commons.httpclient.protocol.DefaultProtocolSocketFactory.createSocket(DefaultProtocolSocketFactory.java:122)
at org.apache.commons.httpclient.HttpConnection.open(HttpConnection.java:707)
at org.apache.commons.httpclient.MultiThreadedHttpConnectionManager$HttpConnectionAdapter.open(MultiThreadedHttpConnectionManager.java:1361)
at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:387)
at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171)
at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397)
at org.springframework.http.client.CommonsClientHttpRequest.executeInternal(CommonsClientHttpRequest.java:85)
at org.springframework.http.client.AbstractBufferingClientHttpRequest.executeInternal(AbstractBufferingClientHttpRequest.java:48)
at org.springframework.http.client.AbstractClientHttpRequest.execute(AbstractClientHttpRequest.java:50)
at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:519)
at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:495)
at org.motechproject.openmrs.resource.impl.BaseResource.exchange(BaseResource.java:88)
at org.motechproject.openmrs.resource.impl.BaseResource.exchange(BaseResource.java:83)
at org.motechproject.openmrs.resource.impl.BaseResource.getJson(BaseResource.java:36)
at org.motechproject.openmrs.resource.impl.UserResourceImpl.queryForUsersByUsername(UserResourceImpl.java:33)
at org.motechproject.openmrs.service.impl.OpenMRSUserServiceImpl.getUserByUserName(OpenMRSUserServiceImpl.java:172)
at org.motechproject.openmrs.service.impl.OpenMRSUserServiceImpl.validateUserNameUsage(OpenMRSUserServiceImpl.java:190)
at org.motechproject.openmrs.service.impl.OpenMRSUserServiceImpl.createUser(OpenMRSUserServiceImpl.java:53)
at org.motechproject.openmrs.it.MRSUserServiceIT.createUser(MRSUserServiceIT.java:160)
at org.motechproject.openmrs.it.MRSUserServiceIT.setUp(MRSUserServiceIT.java:49)

Users with the same issue

Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
15 times, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
3 times, 1 month ago
20 more bugmates

Know the solutions? Share your knowledge to help other developers to debug faster.