java.net.SocketException: sendto failed: ENETUNREACH (Network is unreachable)

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

Do you know how to solve this issue? Write a tip to help other users and build your expert profile.

Solutions on the web

via GitHub by YaleZheng
, 1 year ago
sendto failed: ENETUNREACH (Network is unreachable)
via GitHub by postrcase
, 5 months ago
sendto failed: ENETUNREACH (Network is unreachable)
via GitHub by weidongjian
, 1 year ago
sendto failed: ENETUNREACH (Network is unreachable)
via shoutcast.com by Unknown author, 2 years ago
via Google Groups by Micah Akin, 6 months ago
sendto failed: ENETUNREACH (Network is unreachable)
java.net.SocketException: sendto failed: ENETUNREACH (Network is unreachable)
at libcore.io.Posix.sendtoBytes(Native Method)
at libcore.io.Posix.sendto(Posix.java:156)
at libcore.io.BlockGuardOs.sendto(BlockGuardOs.java:177)
at libcore.io.IoBridge.sendto(IoBridge.java:466)
at java.net.PlainDatagramSocketImpl.send(PlainDatagramSocketImpl.java:182)
at java.net.DatagramSocket.send(DatagramSocket.java:281)
at com.qiniu.android.dns.local.Resolver.udpCommunicate(Resolver.java:50)
at com.qiniu.android.dns.local.Resolver.resolve(Resolver.java:34)
at com.qiniu.android.dns.DnsManager.queryInternal(DnsManager.java:132)
at com.qiniu.android.dns.DnsManager.query(DnsManager.java:82)
at com.qiniu.android.http.ClientConnectionOperator.systemResolv(ClientConnectionOperator.java:243)
at com.qiniu.android.http.ClientConnectionOperator.openConnection(ClientConnectionOperator.java:141)
at cz.msebera.android.httpclient.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:145)
at cz.msebera.android.httpclient.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:131)
at cz.msebera.android.httpclient.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:611)
at cz.msebera.android.httpclient.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:446)
at cz.msebera.android.httpclient.impl.client.AbstractHttpClient.doExecute(AbstractHttpClient.java:860)
at cz.msebera.android.httpclient.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82)
at com.loopj.android.http.AsyncHttpRequest.makeRequest(AsyncHttpRequest.java:146)
at com.loopj.android.http.AsyncHttpRequest.makeRequestWithRetries(AsyncHttpRequest.java:177)
at com.loopj.android.http.AsyncHttpRequest.run(AsyncHttpRequest.java:106)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:422)
at java.util.concurrent.FutureTask.run(FutureTask.java:237)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)
at java.lang.Thread.run(Thread.java:841)

Users with the same issue

6 times, 2 months ago
Samebug visitor profile picture
Unknown user
Once, 2 years ago
1183 times, 1 year ago
327 times, 6 months ago
6 times, 1 year ago

Write tip

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