Setting Up a Front-End NLB Cluster
- Clustering Basics
- Setting Up Your Front-End NLB Cluster
- Wrapping Up
I can't remember the last time either msn.com or msnbc.com was down. Can you? Have you ever wondered why?
For some time now, Microsoft and other large companies that offer services over the Web have had their sites clustered and load balanced, which helps to keep the sites up and running constantly. In this article, you'll learn how to set up a front-end cluster for your own system, using the Windows Server 2003 (Win2k3) Network Load Balancing (NLB) driver. Then maybe your site can stay up and stable, as these sites do.
Clustering Basics
Win2k3 offers several types of clustering services; for this article, we'll focus on the simple NLB cluster scenario.
Businesses typically cluster their servers into two parts: a front-end cluster and a back-end cluster. NLB is ideal for a front-end cluster configuration, and Microsoft Cluster Service (MSCS) is commonly used for a back-end cluster configuration.
Front-End Cluster Configuration
Think of the front end as what the user first encounters when reaching a Web site that has been clustered. The process goes something like this:
The user issues a static requestthat is, a request for a Web page with static content (content that's not generated dynamically, such as from a database).
The NLB front-end clustered server group routes the user's request to an available Internet Information Services (IIS) server.
The server handles the request.
The process is repeated with each subsequent request, but with a different server in the group handling the new request.
Because the requests are divided among the group of clustered servers, thus improving both performance and availability of the Web site, the cluster is said to be load balanced.
NOTE
All these processes are transparent to the user, and it appears that just one machine is handling the requests; therefore, the set of clustered servers is often referred to as a virtual server.
NLB is good for a front-end Web cluster configuration because it handles such TCP/IP requests and distributes them across several machines at the network layer, but it's not ideal for a back-end clustered configuration. Why not?
Suppose a machine in this front-end cluster must be taken off the network to add new hardware or for maintenance. The NLB cluster won't route requests to that machine while it's offline, instead using the other servers in the group to handle requests. When you plug the machine back into the network, NLB detects it.
All well and good. But what happens if a service, such as IIS, is no longer functioning on a machine in the cluster? NLB can't detect that the service isn't running; instead, the NLB cluster keeps sending requests to a machine that no longer has the Web server running. Not only will this error cause a performance penalty, but the user who happens to get that machine will get a "Page cannot be displayed" message. Therefore, you shouldn't use NLB for mission-critical services such as messaging or database services.
Back-End Cluster Configuration
Think of the back end as the requests that come from your Web sitesfor example, requests to an email server or a database serverin a process something like this:
The user issues a dynamic requestthat is, a request for a Web page with dynamic content generated from a database.
The NLB front-end clustered server group routes the user's request to an available IIS server.
IIS processes the request with a call to a database server on the MSCS configured back-end cluster.
The two clustered configurationsfront end and back endwork together to create a "layered" cluster using the two types of clustering services. Makes sense, doesn't it? You have to access the front end to reach the back end.
If a service or machine in a back-end cluster fails, another in the cluster takes control and handles all the requests (unlike a load-balanced configuration, where several machines share the requests). In essence, a back-end cluster is more reliable than a front-end cluster; it's just not as scalable. Windows 2000 Advanced Server allowed an MSCS cluster with two nodes; in Win2k3, you can have up to four nodes per cluster.