[squid-users] Help: How to calculate all bytes when communicate with client for a request

wei edwin.zhou at hotmail.com
Tue Dec 20 10:56:30 UTC 2016

Hi Guys,

I want to calculate all bytes when a request is sent to squid, including:

  1.  the header length that client will send to squid
  2.  the post content length that send to squid
  3.  the response length squid will reply to client

logformat squid %ts.%03tu %6tr %>a %Ss/%03Hs %<st %rm %ru %un %Sh/%<A:%<a %mt %st

In the squid config file, I can only set %st which only include 1 and 3, seems squid ignore the point 2(the post content length is not included in the total size), it also happens when a post request occurs in squid https connection.

I don't need to know the request content, just want to know how many bytes the client totally send including the post and https bytes, is it possible to do this?

Is it possible to modify the squid source code if there is no parameter to control this? Is it just a counting logic that won't be complex? Any help would be much appreciated. Thanks.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squid-cache.org/pipermail/squid-users/attachments/20161220/04adb279/attachment.html>

More information about the squid-users mailing list