1 #include "$(ROOT)/.wml/template.inc" section=gallery subsection=alex-01
3 <H1>Billing Cross Check</H1>
5 <P>by <A HREF="mailto:alex@ergens.op.Het.Net">Alex van den Bogaerdt</A></P>
7 <P>
8 Our internet provider does usage based billing. Part of the bandwidth
9 is at a fixed price, the remaining bandwidth is subject to UBB.</P>
11 <P>The UBB works as follows: every sample period the current bandwidth is
12 calculated. When it is above the UBB rate, the excess is used to build
13 an average over a month. This average is used to calculate the bill.</P>
15 <P>I do trust the provider however I do not necessarily trust their billing
16 system. Therefore I need a way to check the bill.</P>
18 <P>Normal usage would be to graph from the 1st of the previous month until
19 the 1st of the current month. RRDtool does all the calculations, using
20 CDEF statements. I use bash to collect the prices from a database, then
21 start the RRDtool script with those variables filled in.</P>
23 <P>The data that I used to create the image has been altered to protect
24 our privacy and the providers pricing policy (meaning: its bogus data).
25 It does show however how it works. If I create the graph using correct
26 values for start and end times, the only difference should be caused by
27 rounding and by different polling times.</P>
29 <P><IMG SRC="alex-01.png"></P>
31 <P>If you are interested in the script generating this, get it
32 <A HREF="alex-01.bash">here</A>.</P>