tailscale/net/interfaces
Josh Bleecher Snyder ad5e04249b wgengine/monitor: ignore adding/removing uninteresting IPs
One of the most common "unexpected" log lines is:

"network state changed, but stringification didn't"

One way that this can occur is if an interesting interface
(non-Tailscale, has interesting IP address)
gains or loses an uninteresting IP address (link local or loopback).

The fact that the interface is interesting is enough for EqualFiltered
to inspect it. The fact that an IP address changed is enough for
EqualFiltered to declare that the interfaces are not equal.

But the State.String method reasonably declines to print any
uninteresting IP addresses. As a result, the network state appears
to have changed, but the stringification did not.

The String method is correct; nothing interesting happened.

This change fixes this by adding an IP address filter to EqualFiltered
in addition to the interface filter. This lets the network monitor
ignore the addition/removal of uninteresting IP addresses.

Signed-off-by: Josh Bleecher Snyder <josh@tailscale.com>
2021-11-22 16:33:15 -08:00
..
interfaces.go wgengine/monitor: ignore adding/removing uninteresting IPs 2021-11-22 16:33:15 -08:00
interfaces_darwin.go net/interface: remove darwin fetchRoutingTable workaround 2021-05-10 08:24:11 -07:00
interfaces_darwin_test.go net/{dnscache,interfaces}: use netaddr.IP.IsPrivate, delete copied code 2021-07-26 20:30:28 -07:00
interfaces_default_route_test.go all: gofmt with Go 1.17 2021-08-05 15:54:00 -07:00
interfaces_defaultrouteif_todo.go all: gofmt with Go 1.17 2021-08-05 15:54:00 -07:00
interfaces_linux.go net/{dnscache,interfaces}: use netaddr.IP.IsPrivate, delete copied code 2021-07-26 20:30:28 -07:00
interfaces_linux_test.go net/interface: add AWS App Runner /proc/net/route test 2021-07-14 10:01:14 -07:00
interfaces_test.go wgengine/monitor: ignore adding/removing uninteresting IPs 2021-11-22 16:33:15 -08:00
interfaces_windows.go net/interfaces/windows: update Tailscale interface detection logic to 2021-11-08 07:44:33 -08:00
interfaces_windows_test.go net/interfaces: quiet PAC detection logging in no-PAC case, add benchmark 2020-10-01 22:02:39 -07:00