Log slow responses
Kristian Lyngstol
kristian at varnish-software.com
Tue Mar 9 12:05:25 CET 2010
On Mon, Mar 08, 2010 at 05:48:32PM -0800, Brad Schick wrote:
> Is there a way to get varnishlog to print requests that take over a
> certain amount of time to complete? My understanding is that ReqEnd
> contains:
> XID req_timestamp comp_timestamp idle_time proc_time xmit_time
>
> I'd like to print entries that have xmit_time over a certain amount.
You can do it with a regex:
$ varnishlog -c -o ReqEnd '1\.[0-9]+$'
This will catch requests that take 1.x seconds.
varnishlog -c -o ReqEnd '[1-9]+\.[0-9]+$'
Will catch requests taking 1 or more seconds, 11 seconds, 12 seconds etc.
Finding one that takes 1+ (including 10) seconds is left as an exercise to
the reader.
- Kristian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20100309/433724ee/attachment-0003.pgp>
More information about the varnish-misc
mailing list