Multiple backends on same server (cPanel)

Jerry Steele ticktockhouse at
Mon Mar 24 15:37:34 CET 2014


So, this now appears to work:

backend default {
  .host = "";
  .port = "8081";

backend default2 {
  .host = "";
  .port = "8081";

sub vcl_recv {

if ( ~ "$";) {
      set req.backend = default2;

Is "default" some kind of builtin? The fact that the other
virtualhosts are working, to me, says that they're being sent to the
default backend, and only requests going to * are being
sent to the "default2" backend. varnishlog appears to confirm this.

One other issue - I changed this last night, and it appeared not to
work, however, I come back to it this morning, and everything is fine.
Does this mean that the old configuration (or objects that the new
config was looking for) had been cached, and their TTL had to expire?
If this is the case, where are these defaults set? Is it necessary to
manually clear the cache when changing configs like this? I believe
there's a curl command to do this...



Jerry Steele
Telephone: +44 (0)7920 237105

More information about the varnish-misc mailing list