[Varnish] #1619: Varnishncsa does not log 304
Varnish
varnish-bugs at varnish-cache.org
Mon Oct 27 16:41:18 CET 2014
#1619: Varnishncsa does not log 304
---------------------------------+-------------------------
Reporter: vrobert | Type: defect
Status: new | Priority: high
Milestone: Varnish 4.0 release | Component: varnishncsa
Version: 4.0.2 | Severity: major
Keywords: varnishncsa 304 |
---------------------------------+-------------------------
Hi,
since that we migrated to varnish 4 (0.1 or 0.2), we had not 304 in log.
If a conditional request arrives, a 304 code could be send by Varnish, but
it's never logged by varnishncsa.
Instead of 304, a 200 with Content-Lenght at 0 byte is logged.
ex:
{{{
93.17.51.134 - - [27/Oct/2014:16:05:24 +0100] "GET http://www.ouestfrance-
auto.com/voiture-occasion/passat-cc-2-0-tdi-140-dsg-carat/ HTTP/1.1" 200 0
"-" "Mozilla/5.0 (compatible; Googlebot/2.1;
+http://www.google.com/bot.html)" hit 0.000162
}}}
for the request :
{{{
curl -v --header 'If-Modified-Since: Mon, 27 Oct 2014 14:58:36 GMT' -A
"Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)"
"http://www.ouestfrance-auto.com/voiture-occasion/passat-cc-2-0-tdi-140
-dsg-carat/"
* About to connect() to www.ouestfrance-auto.com port 80 (#0)
* Trying 212.95.70.231... connected
* Connected to www.ouestfrance-auto.com (212.95.70.231) port 80 (#0)
> GET /voiture-occasion/passat-cc-2-0-tdi-140-dsg-carat/ HTTP/1.1
> User-Agent: Mozilla/5.0 (compatible; Googlebot/2.1;
+http://www.google.com/bot.html)
> Host: www.ouestfrance-auto.com
> Accept: */*
> If-Modified-Since: Mon, 27 Oct 2014 14:58:36 GMT
>
< HTTP/1.1 304 Not Modified
< Date: Mon, 27 Oct 2014 09:45:49 GMT
< Content-Type: text/html
< Vary: Accept-Encoding
< X-Powered-By: PHP/5.5.12
< Expires:
< Cache-Control: public, max-age=1800
< Pragma:
< Access-Control-Allow-Origin: *
< Access-Control-Allow-Methods: GET, POST
< Access-Control-Allow-Headers: X_OFA
< x-url: www.ouestfrance-auto.com/voiture-occasion/passat-cc-2-0-tdi-140
-dsg-carat/
< h-url: /voiture-occasion/passat-cc-2-0-tdi-140-dsg-carat/
< X-Varnish: 674201926 491946724
< Via: 1.1 varnish-v4
< X-Age: 19175
< grace: full(bot)
< X-Served-By: ofm-proxy01.sdv.fr
< Connection: keep-alive
<
* Connection #0 to host www.ouestfrance-auto.com left intact
* Closing connection #0
}}}
--
Ticket URL: <https://www.varnish-cache.org/trac/ticket/1619>
Varnish <https://varnish-cache.org/>
The Varnish HTTP Accelerator
More information about the varnish-bugs
mailing list