LOAD-BALANCING – POUND (ENG)

Today, we will see how to set up Pound, a reverse proxy that will allow us to load-balancing between several websites.

PREREQUISITES

  1. A machine with pound
  2. In my situation, I use 3 web servers

INSTALLATION OF POUND

First, start by updating your machine.

apt-get update && apt-get upgrade

Then install pound.

apt-get install -y pound

CONFIGURATION OF POUND

The configuration of pound is done in the file /etc/pound/pound.cfg:

nano /etc/pound/pound.cfg

First, we declare the IP address 10.0.24.109 (the IP address of the Pound machine) as the IP address that we will use to access the 3 websites.

3) pound conf


Then we declare the 3 IP addresses of the 3 web servers that we have set up to indicate to the pound server on which web servers it will do the load distribution.

4) pound conf 2


Once you have declared your servers, you must set the pound service to be active at default startup:

nano /etc/default/pound

6) startup 1

Now restart the pound service.

service pound restart

If all is correct, normally when you enter the IP address of the machine with pound, it will redirect you to one of the 3 websites.

Then update the web pages several times and you will find that pound will redirect you randomly to one of the 3 websites.

8.1) test.PNG

8.2) test

8.3) test

 

SOURCE: https://phelepjeremy.wordpress.com/2017/12/11/reverse-proxy-pound-load-balancing/

Publicités

Laisser un commentaire

Entrez vos coordonnées ci-dessous ou cliquez sur une icône pour vous connecter:

Logo WordPress.com

Vous commentez à l'aide de votre compte WordPress.com. Déconnexion /  Changer )

Photo Google+

Vous commentez à l'aide de votre compte Google+. Déconnexion /  Changer )

Image Twitter

Vous commentez à l'aide de votre compte Twitter. Déconnexion /  Changer )

Photo Facebook

Vous commentez à l'aide de votre compte Facebook. Déconnexion /  Changer )

Connexion à %s