Hi,

> perhaps that's a bit off topic here but can someone explain what I need to 
> build a hardware failover nginx cluster?
Nope, but define hardware. A loadbalancer does not care what OS you are 
running, it does care what service it needs to balance. So, would "a debian 
server running loadbalancer software" be a  "hardware load balancer" or are you 
talking abount a "real" hardware load balancer like a <insert brandname> 
device. 

>The unclear is:
> How does the client know that the server 1 is down and use the other one?
> DNS failover has a delay because of the design I think.

A load balancer does NOT leave it up to the client to select the server, that 
is what the load balancer is for. The client sees just 1 ip number, that of the 
load balancer. After that the loadbalancer makes sure that the client gets 
redirected to one of the active servers. If the server/service suddenly dies 
the loadbalancer will not get a reply from the service/service when it wants to 
redirect the next client and remove that server from the active list and 
redirect the client to the next active server. All of that happens on "the 
other side" of the loadbalancer and is hidden from the client.

With https the SSL session will end on the loadbalancer and depending on the 
configuration will either go via straight http or a new https session to the 
real server. Usually the first because of performance, security should not be 
an issue on the internal network.

>client ---> SRV1
>     |---> SRV2 (failover if SRV1 is down and load balancing)
This is called dns round robbin balancing and depending on who you asks is not 
"real loadbalancing". It does balance the load but when a server / service dies 
that server is still in the dns list and it needs a smart client to skip the 
dead server and go to the next in the list. Also in that case any session 
information will get lost unless there is some smart mechanism with which the 
servers in the cluster share session information. A real load balancer will 
usually recognize a client when it comes back for more information and send to 
the same server if there is any need for that.

> how did it work on google or somethink else?
>
[...]
;; ANSWER SECTION:
google.de.              300     IN      A       173.194.32.255
google.de.              300     IN      A       173.194.32.247
google.de.              300     IN      A       173.194.32.248

There are 3 ip addresses. Those 3 addresses each point to a load balancer and 
not to a server. The client does not know that, it simply sees 1 ip number to 
which it will send the request and get the reply from. 

> Is that load balance or failover?
It is a combination. There are 3 loadbalancers for failover in case a 
loadbalancer dies / has maintenance / whatever.

Bonno Bloksma


--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: 
https://lists.debian.org/89d1798a7351d040b4e74e0a043c69d77b148...@hglexch-01.tio.nl

Reply via email to