solution for Active/Passive Backend

Guillaume Quintard guillaume at varnish-software.com
Sat Jul 4 15:11:36 UTC 2020


Hi,

You want to use probes and the fallback director.

Relevant documentation:
to define a probe:
https://varnish-cache.org/docs/6.4/reference/vcl.html?highlight=probe#probes
to attach it to backends:
https://varnish-cache.org/docs/6.4/reference/vcl.html?highlight=probe#backend-definition
the fallback director:
https://varnish-cache.org/docs/6.4/reference/vmod_directors.html?highlight=fallback#directors-fallback

i also wrote these blog posts a long time ago, but they are still valid:
https://info.varnish-software.com/blog/backends-load-balancing
https://info.varnish-software.com/blog/backends-load-balancing-part-2

The first one goes through probes, and the second one explores directors,
including the fallback one.

Hope that helps

-- 
Guillaume Quintard


On Sat, Jul 4, 2020 at 7:14 AM hamidreza hosseini <hrhosseini at hotmail.com>
wrote:

> Hi,
> I want to have 2 or 3 backends in the Varnish config file but just one of
> them workes as an active backend and whenever my active backend failed ,
> the second backend become active and respond the requests. (In other hand,
> I dont want to have two backend for responding clients and just one of them
> works at the same time, and it check the health status of my active backend
> , whenever it is was unhealthy , varnish switch to the second or third
> backend.)
> Best Regards.
> _______________________________________________
> varnish-misc mailing list
> varnish-misc at varnish-cache.org
> https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20200704/be130ed2/attachment-0001.html>


More information about the varnish-misc mailing list