diff --git a/ethereum/p2p/src/main/java/tech/pegasys/pantheon/ethereum/p2p/discovery/PeerDiscoveryAgent.java b/ethereum/p2p/src/main/java/tech/pegasys/pantheon/ethereum/p2p/discovery/PeerDiscoveryAgent.java index 3277a5c7a8..38ee86478a 100644 --- a/ethereum/p2p/src/main/java/tech/pegasys/pantheon/ethereum/p2p/discovery/PeerDiscoveryAgent.java +++ b/ethereum/p2p/src/main/java/tech/pegasys/pantheon/ethereum/p2p/discovery/PeerDiscoveryAgent.java @@ -41,6 +41,7 @@ import tech.pegasys.pantheon.util.bytes.BytesValue; import java.net.InetSocketAddress; +import java.net.SocketException; import java.util.Collection; import java.util.Collections; import java.util.List; @@ -204,11 +205,16 @@ protected void handleOutgoingPacket(final DiscoveryPeer peer, final Packet packe .whenComplete( (res, err) -> { if (err != null) { - LOG.warn( - "Sending to peer {} failed, packet: {}", - peer, - wrapBuffer(packet.encode()), - err); + if (err instanceof SocketException && err.getMessage().contains("unreachable")) { + LOG.debug( + "Peer {} is unreachable, packet: {}", peer, wrapBuffer(packet.encode()), err); + } else { + LOG.warn( + "Sending to peer {} failed, packet: {}", + peer, + wrapBuffer(packet.encode()), + err); + } return; } peer.setLastContacted(System.currentTimeMillis());