Presentation of NLB
Network Load Balancing (NLB) is a feature built into Windows that allows the implementation of load balancing at the network level. It is often used with IIS / FTP / RDS.
NLB works with a virtual IP address that is available to all hosts in the cluster.
NLB supports up to 32 nodes on the same cluster, according to Microsoft best practices it is advisable to create clusters of maximum 8 nodes.
The NLB feature relies on network-level distribution, one of the limitations of this solution is that the heatbeats tests monitor whether the hosts are online and not the service. If the web service of one of the hosts is non-functional but the host responds to the HB, requests will be sent to the host.
Representation of an NLB cluster in monodiffussion :
Setting up a Network Load Balancing Cluster you need:
- At least two servers with the same service installed (for this lab I used two IIS web servers) and two network cards. A card will be for server management and a dedicated NLB cluster card. If the NLB cluster is configured in Multidiffussion it is not necessary to have two network cards.
- At least 3 IPs: 1 IP for the cluster that will be virtual and an IP address for each node
If your servers are under Hyper-V, you must activate the MAC address spoofing on network adapters dedicated to the NLB cluster.
Modes of transmission
Unicast: the default mode, it will disable the MAC address of the network card and replace it with an identical virtual address on all nodes.
Multicast: recommended mode, it can be used with one or more network cards. With this mode, the network adapter will have two MAC addresses, the one on the network adapter and the virtual MAC address of the cluster.