A few users see a blank page

Marco Molinari marco.molinari at gmail.com
Wed Feb 13 16:50:10 CET 2008

On Feb 13, 2008 4:33 PM, Dag-Erling Smørgrav <des at linpro.no> wrote:
> You are doing weird things such as inserting passed requests into the
> cache, yet none of the requests you showed were cache hits.
> Re the second request from your log, where the client got an empty
> page: that was actually what the backend sent.

actually Apache logged it sent 8001 bytes:, - - [12/Feb/2008:14:24:29 +0100] "GET
/test_varnish2.php?n=11&t=1202822659 HTTP/1.0" 200 8001 "-"

> There is no way to debug this further without seeing your vcl script.

Here the vcl I posted, which was the one I was using:

backend default {
       set backend.host = "";
       set backend.port = "8080";

sub vcl_recv {
       if (req.http.Pragma == "no-cache") {

       if (req.request == "GET" && req.url ~
"\.(gif|jpg|swf|css|js|swf|flv|png|jpeg)$") {

       if (req.request != "GET" && req.request != "HEAD") {

       if (req.http.Expect) {

       if (req.http.Authenticate || req.http.Cookie) {


Today I changed the last "pass" into "pipe" (in the req.http.Cookie
part) and both I and my complaining users get no blank pages anymore
(Arne, I remember you wrote you tried both pipe and pass, but did you
try this?)

To sum this up, I get a blank page if all of these happen:
- I use a Squid 2.5 or 2.6 proxy
- and the content is generated by php
- and the content is more than 8000 bytes
- and the cookie header is quite long (about 500 chars)
- and if (req.http.Cookie) {pass} in vcl


More information about the varnish-misc mailing list