LinuxSA Mailing list archives
Index:
[thread]
[date]
[subject]
[author]
[stats]
From: Andrew Reid <andrew.reid@plug.cx>
To : Ken Evans <subcriptions@bettanet.net.au>
Date: Sun, 18 Nov 2001 16:04:22 +1030
Re: internet cafe monitor/billing software
On Sun, Nov 18, 2001 at 09:56:13AM +1030, Ken Evans wrote:
> eg user gets so much time allocated to use a machine, print tickets so they
> can come back and reuse with login etc until time expires, receipts, all
> terminals communicate with server for logins, time, and cost functions etc,
> locks terminals and only allows programs specified to be used etc
Charging for Internet use via time when you're (probably) connected to
broadband is a rather bad way of doing it.
For example, if you've got a link that peaks at 500KBps, a user could
download a theoretical maximum of 1.8GB. If you're getting charged at,
say, $0.15 / MB (a reasonably low figure), you're going to be able to
run up a bill of $270 every hour.
Let k = maximum kilobytes per second
Let p = maximum cost per hour
p = (k / 1024) * (60*60)
That's pretty unlikely in most Internet Cafe's, as you're probably not
providing much in the way of mass storage. Even if you were, there's
the issue of getting the downloaded material off the machine.
The solution is obvious: charge on a per megabyte basis.
The simplest way of doing this would probably be to use IP-level byte
counters, using either IPChains or the newer IPTables under Linux, or
if you want to use a real OS, ipfw and IPFilter under FreeBSD.
Just keep a log of who is sitting on which computer (and the IP
address of that machine) and work from there. Just remember to reset
the counter for a particular machine once a new person hops on.
The other way which is slighly more automated involves the use of
Squid and a little bit of magic from Alfred[1]. See the website to get
an idea of what it does and how it does it. Oh, BTW -- I'm maintaining
it these days :-)
Charging per hour is a borked way of doing things unless you're really
careful. Note that there are ways of successfully implementing
per-hour charging. You've just got to make sure that the customer
can't cost you more than what they're paying. The use of bandwidth
limiting pipes are a way of achieving this.
- andrew
--
Andrew J. Reid "Catapultam habeo. Nisi pecuniam omnem
andrew.reid@plug.cx mihi dabis, ad caput tuum saxum immane
+61 401 946 813 mittam"
--
LinuxSA WWW: http://www.linuxsa.org.au/ IRC: #linuxsa on irc.linux.org.au
To unsubscribe from the LinuxSA list:
mail linuxsa-request@linuxsa.org.au with "unsubscribe" as the subject
Index:
[thread]
[date]
[subject]
[author]
[stats]
Return to the LinuxSA Mailing List Information Page