diff options
author | Nick Mathewson <nickm@torproject.org> | 2012-12-18 15:16:35 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2012-12-18 15:16:35 -0500 |
commit | 7a99d26c798a2223c8277e6c358eb76195d18dab (patch) | |
tree | 7584778c1d568ad994e9bb2e0dfcd3c36aaeca1c | |
parent | a60680c2267706db081699445abcbcde4a81c526 (diff) | |
download | tor-7a99d26c798a2223c8277e6c358eb76195d18dab.tar tor-7a99d26c798a2223c8277e6c358eb76195d18dab.tar.gz |
Add packaged cell fullness to the heartbeat message.
This is an attempt to diagnose the severity of bug 7743.
-rw-r--r-- | changes/hb-fullness | 3 | ||||
-rw-r--r-- | src/or/status.c | 6 |
2 files changed, 9 insertions, 0 deletions
diff --git a/changes/hb-fullness b/changes/hb-fullness new file mode 100644 index 000000000..5a8beb8a0 --- /dev/null +++ b/changes/hb-fullness @@ -0,0 +1,3 @@ + o Minor features: + - Log packaged cell fullness as part of the heartbeat message. + Diagnosis to try to determine the extent of bug 7743. diff --git a/src/or/status.c b/src/or/status.c index fc01d0a24..1a4e56885 100644 --- a/src/or/status.c +++ b/src/or/status.c @@ -10,6 +10,7 @@ #include "config.h" #include "status.h" #include "nodelist.h" +#include "relay.h" #include "router.h" #include "circuitlist.h" #include "main.h" @@ -106,6 +107,11 @@ log_heartbeat(time_t now) "circuits open. I've sent %s and received %s.", uptime, count_circuits(),bw_sent,bw_rcvd); + if (stats_n_data_cells_packaged) + log(LOG_NOTICE, LD_HEARTBEAT, "Average packaged cell fullness: %2.3f%%", + 100*(U64_TO_DBL(stats_n_data_bytes_packaged) / + U64_TO_DBL(stats_n_data_cells_packaged*RELAY_PAYLOAD_SIZE)) ); + tor_free(uptime); tor_free(bw_sent); tor_free(bw_rcvd); |