Setting Up Your Front-End NLB Cluster
It's time to get our hands dirty. We'll set up a simple front-end NLB cluster using two Windows 2003 servers with IIS 6.0 installed.
I won't go into details on every dialog box option in the following example; I'll just provide enough information to get you started.
Use the checklist below to make sure that you have all the proper hardware and software for setting up the NLB cluster:
Two Windows Server 2003 (Standard or Enterprise) nodes
Two network cards for each Windows Server 2003 box
IIS 6.0 installed and running on each box
LAN crossover cable
This is all the hardware and software you need for the cluster, but you'll also need a DNS server running on your subnet if you're using NetBIOS over TCP/IP (enabled by default).
NetBIOS over TCP/IP is the network component that performs computer nametoIP address mapping. This service often checks your DNS server for machinetoIP mappings when resolving a name request on your network.
Before entering parameters for the network connections, use the Add/Remove components applet from the control panel to make sure that IIS 6.0 is installed and running on each box (it's not loaded by default). Each server requires two network cards: one for the private network or heartbeat, and the other for the public network. The private adapter requires a crossover cable that runs between what will be the two clustered servers. The public adapter is the one with Internet connectivitythe adapter that handles all client requests.
In Win2k, there was no convenient way to set up or manage NLB clusters from one server. Win2k3 offers a new tool for this purpose, called the Network Load Balancing Manager, NLB Manager for short. I recommend learning more about NLB Manager for managing large NLB clusters. Because we're only setting up a two-node cluster in this example, we'll enter the parameters manually. This will give you a better understanding of what NLB Manager does automatically. (After we set up the cluster, you can connect to it using the NLB Manager if necessary.)
Assuming that you have everything ready to go, let's get started by entering the parameters for the private network. Designate one of the network cards in each box to be the private adapter. This adapter doesn't accept client requests; it communicates with the other cluster node. The numbers entered here must be privateand not in use by any other network cards on the network. A common practice is to use the 10.0.0.0 private IP range. Start by entering the TCP/IP properties for this connection as shown in Figure 1.
Figure 1 Entering the private connection parameters.
No gateway is necessary, as this connection doesn't need Internet connectivity. You don't need a DNS server for this connection, but I like to use one on the network anyway. Confirm these parameters, and rename this connection as Private. Now set up your other private connection on the other server. Don't use the same IP address; instead, use the next one in the range (for example, 10.0.0.2).
Now we can move on to the public connections. Enter your network card's public IP address in the TCP/IP Properties dialog box for this connection. Figure 2 shows that I used another private IP range, but only because I'm working behind a firewall. The numbers I entered also have an external IP mapped to them; your situation may be similar. Be sure to include your Internet gateway and DNS server.
Figure 2 Entering the public connection parameters.
Load Balancing Properties
In the Network Load Balancing Properties dialog box, the settings on the Cluster Parameters tab should look something like those shown in Figure 3. In the Cluster IP Configuration section, enter the cluster's virtual IP addressthe IP number that ties together all machines in the cluster. Any machine in the cluster takes on this address when handling a request. Use an IP number that's not used anywhere else on your network. Because both servers in the cluster will use this address, the settings here must be identical to those of the other machine in the cluster.
Next, enter the subnet mask and cluster domain name. The cluster domain name is simply a way of keeping track of a cluster in Active Directory. It has nothing to do with a domain that resolves to a Web site. Just think of it as an internal name for your cluster, much like your machine gets when it becomes part of a domain. For the other parameters, accept the default selections.
Multicast support is checked only if you're using one network card. That doesn't apply in our example.
Figure 3 Entering the NLB cluster parameters.
On the Host Parameters tab, enter the server's static IP addressnot the cluster IP addressand subnet mask in the Dedicated IP Configuration section (see Figure 4). Notice that these are the same numbers you entered in the TCP/IP Properties dialog box for the connection. Leave the unique host identifier set as 1. Each machine in our cluster will need a unique ID, and this is it. When setting up the parameters for the other server, we'll use 2 as the unique host identifier.
Figure 4 Entering the NLB host parameters.
There's one last task before you can move on to setting up the other server's public connection. You may have received a message indicating that you should enter the cluster IP in the TCP/IP settings for the connection. To do this, click the Advanced button in the TCP/IP Properties dialog box for the connection, and add your cluster IP to the IP address list for this connection (see Figure 5).
Figure 5 Adding the cluster IP to TCP/IP.
That's it! You're done with this machine. Set up the public connection for your other server in the same manner. All that changes is the static IP address for the server. The cluster parameters should be identical.
When both machines have been configured, go to your DNS server and enter a zone for the cluster, using the cluster's DNS name (in our example, cluster1.xeonlabs.com). Tie the cluster IP to this name using an A record, and make sure that each machine in the cluster is tied to its public static IP in DNS.