logging request time

Vladimir Stavrinov vstavrinov at gmail.com
Thu Nov 8 09:23:57 CET 2012

On Wed, Oct 31, 2012 at 10:05:52PM +0100, Jorge Nerín wrote:

>    Well, currently I use an indirect method, the ss utility & a quick'n'dirty perl one liner:
>    ss -i -t 'sport = :80' |perl -e 'while (<>) { if (m/send (.*?)([M|K|]bps) /){ ($s,$u)=($1,$2); $s=$s*1000000 if ("Mbps"
>    eq "$u"); $s=$s*1000 if ("Kbps" eq "$u"); $t=$t+$s; $c=$c+1}} print "$t total bps, $c clients: ", ($t/$c) , " avg.
>    bps\n" '
>    The "output" looks like:
>    1352182000 total bps, 539 clients: 2508686.45640074 avg. bps
>    I'm working on a munin plugin with this idea, as I'm testing different tcp congestion avoidance algorithms and playing
>    with initcwnd & initrwnd and I like to keep track of the changes.

I don't understand what for all of this. It is totally off topic. What
we need is the time of each request to write to ncsa log file similar to
what exists in apache and nginx log. There are lot of others parameters
in this file that are needed all together for using by many kinds of log
analyzers. It should be done not by external tools, but by varnish
itself like other web or proxy servers are doing. And I don't understand
why this simple and necessary thing is not implemented yet.  


##  Vladimir Stavrinov
##  vstavrinov at gmail.com

More information about the varnish-misc mailing list