Skip to content

Instantly share code, notes, and snippets.

@elico
Created February 1, 2017 20:10
Show Gist options
  • Save elico/2ea2253ef1c09872ba90becb961acd91 to your computer and use it in GitHub Desktop.
Save elico/2ea2253ef1c09872ba90becb961acd91 to your computer and use it in GitHub Desktop.
squid special access log to help the admin recognize why the request was not served from the local cache proxy
logformat cache_headers %ts.%03tu %6tr %>a %Ss/%03>Hs %<st %rm %ru %[un %Sh/%<a %mt Q-CC: "%{Cache-Control}>h" "%{Cache-Control}>ha" Q-P: "%{Pragma}>h" "%{Pragma}>ha" REP-CC: "%{Cache-Control}<h" REP-EXP: "%{Expires}<h" VARY: "%{Vary}<h"
#"%{Cache-Control}>h" "%{Cache-Control}>ha" "%{Pragma}>h" "%{Pragma}>ha" "%{Cache-Control}<h" "%{Vary}<h"
#"%{User-Agent}>h"
access_log daemon:/var/log/squid/access.log cache_headers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment