[tor-bugs] #13274 [Globe]: mean uptime (monthly) versus mean uptime (weekly) -one has too big rounding errors
Tor Bug Tracker & Wiki
blackhole at torproject.org
Mon Sep 29 10:18:54 UTC 2014
#13274: mean uptime (monthly) versus mean uptime (weekly) -one has too big rounding
errors
------------------------+------------------
Reporter: toralf | Owner: rndm
Type: defect | Status: new
Priority: minor | Milestone:
Component: Globe | Version:
Resolution: | Keywords:
Actual Points: | Parent ID:
Points: |
------------------------+------------------
Comment (by karsten):
Yup, this is a bug in Globe. When it calculates mean uptime it doesn't
distinguish between 0 ("node is down") and null ("no data about uptime or
downtime"). Here's what Onionoo returns for this relay's uptime in the
past week:
{{{
"first": "2014-09-22 09:30:00",
"last": "2014-09-29 09:30:00",
"interval": 3600,
"factor": 0.001001001001001001,
"count": 169,
"values": [
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, null, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, null, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999,
999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, 999
]
}}}
Globe tells me mean uptime is 98.82%. That's 167 times value 999 times
factor 0.001001001001001001 divided by '''169''' values.
What it should calculate is 167 times value 999 times factor
0.001001001001001001 divided by '''167''' values, which is 100%.
By the way, there's a related bug in the graphs which shouldn't drop to
zero in case of null values but which should stop drawing the line and
resume drawing at the next non-null value.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/13274#comment:1>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list