mirror of
https://github.com/tailscale/tailscale.git
synced 2024-12-01 14:05:39 +00:00
net/dns/resolver: don't spam logs on EHOSTUNREACH.
Fixes #1719. Signed-off-by: David Anderson <danderson@tailscale.com>
This commit is contained in:
parent
0141390365
commit
7fab244614
@ -14,6 +14,7 @@
|
|||||||
"math/rand"
|
"math/rand"
|
||||||
"net"
|
"net"
|
||||||
"sync"
|
"sync"
|
||||||
|
"syscall"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
dns "golang.org/x/net/dns/dnsmessage"
|
dns "golang.org/x/net/dns/dnsmessage"
|
||||||
@ -371,6 +372,12 @@ func (c *fwdConn) send(packet []byte, dst netaddr.IPPort) {
|
|||||||
backOff(err)
|
backOff(err)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
if errors.Is(err, syscall.EHOSTUNREACH) {
|
||||||
|
// "No route to host." The network stack is fine, but
|
||||||
|
// can't talk to this destination. Not much we can do
|
||||||
|
// about that, don't spam logs.
|
||||||
|
return
|
||||||
|
}
|
||||||
if networkIsDown(err) {
|
if networkIsDown(err) {
|
||||||
// Fail.
|
// Fail.
|
||||||
c.logf("send: network is down")
|
c.logf("send: network is down")
|
||||||
|
Loading…
Reference in New Issue
Block a user