436
Comment:
|
811
|
Deletions are marked like this. | Additions are marked like this. |
Line 12: | Line 12: |
== Configuration == === Apache === Add the following to `/etc/haproxy/haproxy.cfg` {{{ listen webfarm www:80 mode http balance roundrobin cookie LBN insert indirect nocache option httpclose option forwardfor server haproxy01 www01:80 cookie node1 check server haproxy02 www02:80 cookie node2 check }}} |
HA-proxy
HA-proxy is short for High Availibility proxy. It has features to check that the servers behind it are up, and round robins incoming requests between the servers. HA-proxy can be used with various server types. We will configure two HA-proxys, which later will be running an active/passive setup with Corosync
- 192.168.1.48 haproxy01
- 192.168.1.49 haproxy02
Software
apt-get install haproxy
Configuration
Apache
Add the following to /etc/haproxy/haproxy.cfg
listen webfarm www:80 mode http balance roundrobin cookie LBN insert indirect nocache option httpclose option forwardfor server haproxy01 www01:80 cookie node1 check server haproxy02 www02:80 cookie node2 check