[squid-users] Changing the time format for access_log

James Moe jimoe at sohnen-moe.com
Tue Nov 19 19:08:32 UTC 2019


squid 4.8

I changed the default squid log format

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

to present a more readable fime:
logformat sma1 %Y-%m-%dT%H:%M:%S %z.%03tu %6tr %>a %Ss/%03>Hs %<st %rm %ru %[un
%Sh/%<a %mt

This did not sit well with squid:
$ squid -k parse
...[ bunch o' stuff ]...
2019/11/19 11:32:51| Processing: logformat sma1  %Y-%m-%dT%H:%M:%S %z.%03tu %6tr
%>a %Ss/%03>Hs %<st %rm %ru %[un %Sh/%<a %mt
2019/11/19 11:32:51| storeDirWriteCleanLogs: Operation aborted.
2019/11/19 11:32:51| FATAL: Can't parse configuration token: '%Y-%m-%dT%H:%M:%S
%z.%03tu %6tr %>a %Ss/%03>Hs %<st %rm %ru %[un %Sh/%<a %mt'

What is the format error?

-- 
James Moe
moe dot james at sohnen-moe dot com
520.743.3936
Think.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: OpenPGP digital signature
URL: <http://lists.squid-cache.org/pipermail/squid-users/attachments/20191119/3a33d8fa/attachment.sig>


More information about the squid-users mailing list