How purge all cached pages on a v4 varnish server ? I found this in documentation but how apply the vcl_recv command ?


return(purge) will only purge the hash associated with the request object as it currently stands. What you're describing is a full cache clear. The easiest way to do that is simply to restart Varnish. Failing that, you can also use varnishadm to ban out all URLs, or write a bit of VCL (see https://www.varnish-cache.org/docs/trunk/users-guide/purging.html) to allow you to do the cache clear via a Web request.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.