Merge branch 'maint-0.2.8'

This commit is contained in:
Nick Mathewson 2016-07-01 09:54:08 -04:00
commit 903ec20c0b
2 changed files with 12 additions and 10 deletions

4
changes/bug18849 Normal file
View File

@ -0,0 +1,4 @@
o Minor bugfix (logging):
- Reduce excessive logging when directories can't be found.
Fixes bug 18849; bugfix on 0.2.8.3-alpha and 0.2.8.1-alpha.
Patch by teor.

View File

@ -1764,20 +1764,18 @@ router_picked_poor_directory_log(const routerstatus_t *rs)
#endif #endif
/* We couldn't find a node, or the one we have doesn't fit our preferences. /* We couldn't find a node, or the one we have doesn't fit our preferences.
* This might be a bug. */ * Sometimes this is normal, sometimes it can be a reachability issue. */
if (!rs) { if (!rs) {
static int logged_backtrace = 0; /* This happens a lot, so it's at debug level */
log_info(LD_BUG, "Wanted to make an outgoing directory connection, but " log_debug(LD_DIR, "Wanted to make an outgoing directory connection, but "
"all OR and Dir addresses for all relays were not reachable. " "we couldn't find a directory that fit our criteria. "
"Check ReachableAddresses, ClientUseIPv4, and similar options."); "Perhaps we will succeed next time with less strict criteria.");
if (!logged_backtrace) {
log_backtrace(LOG_INFO, LD_BUG, "Node search initiated by");
logged_backtrace = 1;
}
} else if (!fascist_firewall_allows_rs(rs, FIREWALL_OR_CONNECTION, 1) } else if (!fascist_firewall_allows_rs(rs, FIREWALL_OR_CONNECTION, 1)
&& !fascist_firewall_allows_rs(rs, FIREWALL_DIR_CONNECTION, 1) && !fascist_firewall_allows_rs(rs, FIREWALL_DIR_CONNECTION, 1)
) { ) {
log_info(LD_BUG, "Selected a directory %s with non-preferred OR and Dir " /* This is rare, and might be interesting to users trying to diagnose
* connection issues on dual-stack machines. */
log_info(LD_DIR, "Selected a directory %s with non-preferred OR and Dir "
"addresses for launching an outgoing connection: " "addresses for launching an outgoing connection: "
"IPv4 %s OR %d Dir %d IPv6 %s OR %d Dir %d", "IPv4 %s OR %d Dir %d IPv6 %s OR %d Dir %d",
routerstatus_describe(rs), routerstatus_describe(rs),