Re: Reg. Report generation

From: Oskar Pearson <>
Date: Wed, 21 Jan 1998 20:46:27 +0200


> Please help me convince people that it is best to use
> proxy and it doesnt affect performance that much..
you mean something like this?

cat access.log | perl -w -e '$misstime = 0;$hittime = 0; while(<>){ while(/\ \ /){s/\ \ /\ /g;} @a = split(/\ /);if ($a[3] =~ /^TCP/){if ($a[3] =~ /MISS\//){$misscount++;$misstime += $a[1];} elsif ($a[3] =~ /HIT/){$hitcount++;$hittime += $a[1];}}} print "time per hit: ",($hittime/$hitcount)," (with $hitcount hits)\ntime per miss: ",($misstime/$misscount)," (with $misscount misses)\n\n";'

I am not sure it's right... it make sense to me though, but
I do throw all sort of data away (that are about errors and the like)

"Haven't slept at all. I don't see why people insist on sleeping. You feel
so much better if you don't. And how can anyone want to lose a minute -
a single minute of being alive?"				-- Think Twice
Received on Wed Jan 21 1998 - 10:50:35 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:38:28 MST