Varnish multi backend directors with failover

By.

min read

My profile

Share this:
sub vcl_int {
    new alpha_rr = directors.round_robin();
    alpha_rr.add_backend(alpha1);
    alpha_rr.add_backend(alpha2);

    new bravo_rr = directors.round_robin();
    bravo_rr.add_backend(bravo1);
    bravo_rr.add_backend(bravo2);
    
    new alpha_fb = directors.fallback();
    alpha_fb.add_backend(alpha_rr.backend());
    alpha_fb.add_backend(err);
    
    new bravo_fb = directors.fallback();
    bravo_fb.add_backend(bravo_rr.backend());
    bravo_fb.add_backend(err);
}

https://info.varnish-software.com/blog/backends-load-balancing-part-2

Share this:

Leave a Reply

Your email address will not be published. Required fields are marked *