[or-cvs] log bytes written with kill -USR1 too
Roger Dingledine
arma at seul.org
Tue Dec 7 16:50:50 UTC 2004
Update of /home2/or/cvsroot/tor/src/or
In directory moria.mit.edu:/home2/arma/work/onion/cvs/tor/src/or
Modified Files:
main.c
Log Message:
log bytes written with kill -USR1 too
Index: main.c
===================================================================
RCS file: /home2/or/cvsroot/tor/src/or/main.c,v
retrieving revision 1.402
retrieving revision 1.403
diff -u -d -r1.402 -r1.403
--- main.c 7 Dec 2004 09:11:38 -0000 1.402
+++ main.c 7 Dec 2004 16:50:47 -0000 1.403
@@ -997,12 +997,18 @@
100*(((double)stats_n_data_bytes_received) /
(stats_n_data_cells_received*RELAY_PAYLOAD_SIZE)) );
- if (stats_n_seconds_uptime)
+ if (stats_n_seconds_uptime) {
log(severity,
- "Average bandwidth used: "U64_FORMAT"/%ld = %d bytes/sec",
+ "Average bandwidth: "U64_FORMAT"/%ld = %d bytes/sec reading",
U64_PRINTF_ARG(stats_n_bytes_read),
stats_n_seconds_uptime,
(int) (stats_n_bytes_read/stats_n_seconds_uptime));
+ log(severity,
+ "Average bandwidth: "U64_FORMAT"/%ld = %d bytes/sec writing",
+ U64_PRINTF_ARG(stats_n_bytes_written),
+ stats_n_seconds_uptime,
+ (int) (stats_n_bytes_written/stats_n_seconds_uptime));
+ }
rep_hist_dump_stats(now,severity);
rend_service_dump_stats(severity);
More information about the tor-commits
mailing list