htaccess redirects not working after a while

Miguel Gonzalez miguel_3_gonzalez at
Tue Dec 11 15:26:50 UTC 2018

Here you have it:
# The data on which the hashing will take placesub vcl_hash {        hash_data(req.url);        if ( {        hash_data(;        } else {        hash_data(server.ip);        }        # If the client supports compression, keep that in a different cache        if (req.http.Accept-Encoding) {                hash_data(req.http.Accept-Encoding);        }        return (lookup);}

>> However I realized that from time to time redirects stop working and I
>> have to purge the Varnish cache and then the redirects work again.

>Can you share the code in your vcl_hash() function? My immediate guess would be that it's not taking into >account the protocol of the request (http vs. https) and giving you wrong cache hits as a result.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the varnish-misc mailing list