Skip navigation

Virtual Server 2005 Cluster Setup Kit

Here's all you need to build a virtualized Windows Server 2003 cluster

One of the most useful features of Microsoft Virtual Server 2005 is its full support for Windows server OSs and for creating clusters in virtual machines (VMs). Using Virtual Server 2005 to create a cluster is easier than you might think. I'll walk you through the process, and you'll soon have a virtualized Windows Server 2003, Enterprise Edition cluster up and running.

Windows 2003 Clusters
Microsoft Clustering Services (MSCS) is the software that enables clustering on various Windows server OSs. MSCS lets multiple systems, called nodes, work together and provide the image of single server as a unit, or cluster, to clients. If one cluster node fails, the node's workload is automatically transferred to the remaining cluster nodes. We'll use Virtual Server 2005 to create and configure a Windows 2003 cluster whose servers are implemented as VMs and are connected to a virtual, shared cluster-storage device. I set up this cluster by using an HP ProLiant ML350 with dual Xeon 3.2 GHz EM64T processors, 2GB of RAM, and 144GB (4 × 36GB) of disk storage. The Web-exclusive sidebar "VM Configuration Summary" at, InstantDoc ID 45902 sums up the details of the sample cluster configuration.

Our sample cluster has two nodes. Each node requires two IP addresses. One address is used for internal communications between the cluster nodes. This internal network passes the cluster heartbeat—essentially a signal that tells each cluster node that the other server is active and available—between nodes. The other address lets external networked systems on your LAN access the cluster.

Creating the Shared Quorum Disk
A key cluster characteristic is the shared storage that the cluster quorum uses. The quorum disk doesn't need to be large—50MB is all the space typically required for a test setup. However, if you're planning to add cluster resources, you'll want to configure a larger quorum disk (100MB to 500 MB), depending on the number of resources you'll add.

To create the shared quorum disk, open Virtual Server Web Administrator by entering the URL http://server:1024/virtualserver/vswebapp.exe?view=1, where server is the name of your Virtual Server 2005 system. Then, to create the virtual hard drive to use for the quorum, click Virtual Disks (in Web Administrator's left frame), Create, Fixed Size Virtual Hard Disk. Virtual Server 2005 doesn't support using a dynamically expanding disk as a cluster's quorum drive, so you must select the Fixed Size Virtual Hard Disk option. Doing so displays a screen like that in Figure 1.

Next, assign a name and directory to the virtual hard disk that will act as the cluster quorum. In Figure 1, you can see that I named my quorum MyClusterQuorum and created it in the Shared Virtual Machines subdirectory, which all the VMs can access. In this way, both cluster nodes can easily access the shared quorum disk.

Configuring the First Node
Your next step is to create the VMs that will serve as the two cluster nodes. To create the first node's VM, click Virtual Machines, Create, which displays the page that Figure 2, shows. In the Virtual machine name field, enter the VM's name (I named it Node1). Next, specify how much memory to allocate to the VM. 256MB, the minimum RAM recommended for a test Windows server installation, is adequate for a test cluster environment.

Now you must create a new dynamically expanding virtual hard disk, which is where Node1's OS will be stored. I used the default size of 16GB. This virtual hard disk isn't shared between the nodes as the quorum drive is.

To let the cluster access your external network, in the Virtual network adapter section you specify External Network, which indicates that the VM will be connected to the host system's external network (in our example, the external network uses an HP NC7761 Gigabit adapter). Virtual Server 2005 gives you two networking options: Internal and External. Internal networks can access only other VMs; external networks can use the host adapter to access your physical network. Although the completed cluster configuration will use both networking types, for now you should select just the external option, then click Create to create the VM.

At this point, we've created a VM named Node1 that has 256MB of RAM, a 16GB IDE virtual hard disk, an IDE CD-ROM device (which Virtual Server adds automatically), and a network interface that's bridged through your host's NIC.

Adding the Quorum to Node1
Now we need to add the shared quorum drive to Node1. Click the Master Status link, then hover the mouse over Node1. Make sure Node1 is powered off and select Edit Configuration from the pop-up window. Before adding the quorum drive, you must set up a SCSI adapter. To do so, in Node1's properties, select the SCSI Adapters option, then click Add SCSI Adapter >> to display the adapter properties page. For SCSI adapter ID, use the default value of 7. Select the Share SCSI bus for clustering check box and click OK.

Next, you'll add to the SCSI adapter the shared hard drive that will be the cluster's quorum drive. To do so, select Node1 on the Web Administrator page, then click Edit Configuration. Click the Hard Disks link, then click Add Disk >>. On the Virtual Hard Disk Properties screen, you should see the dynamically expanding virtual hard drive listed as Virtual hard disk 1 and several blank entry boxes for Virtual hard disk 2—which is where you'll add the information for the shared quorum drive. In the Virtual hard disk 2 section, enter the path to the shared disk (quorum disk) that you created earlier in the Fully qualified path to file box. There's no way to browse for the file, so you must type the path accurately. I used the path C:\Documents and Settings\All Users\Documents\Shared Virtual Machines\MyClusterQuorum.vhd (the default path). To minimize typing, you might want to create these objects close to the root. Then, for Virtual hard disk 2, select SCSI 0 ID 0 for the attachment and click OK. The completed adapter properties should appear similar to the page that Figure 3 shows.

Adding the Internal Network to Node1
You're now ready to add the second virtual NIC that will connect the two cluster nodes. Click the Edit Configuration option for Node1. Click the Network Adapters link, then click Add Network Adapter >>. You'll see the Node1 Network Adapter Properties page, which Figure 4 shows. In the Connected to drop-down box, select Internal Network and click OK. You're now finished configuring the VM for the first cluster node.

Configuring the Second Node
Leave Node 1 powered off and start the configuration process for the second cluster node, Node2. Configuring Node2 is nearly the same as configuring Node1—with two important differences. First, the Node2 VM requires a unique name. Second, the virtual SCSI adapter requires a unique SCSI ID for accessing the shared quorum disk. To create the Node2 VM, click Virtual Machines, Create. Doing so displays the Create Virtual Machine page that Figure 5 shows.

Enter Node2 for the VM name, then fill out the rest of the page exactly as you did for Node1. Select the Create a new virtual hard disk option and create a dynamically expanding virtual hard disk. Leave the Size entry at the default value of 16GB. To let Node2 access the external network, in the Virtual network adapter section specify External Network. You've now created a second VM named Node2 that has 256MB of RAM, a 16GB IDE virtual hard disk, an IDE CD-ROM device, and one NIC that accesses your external network.

Adding the Quorum to Node2
Leave Node2 powered off. To add the shared quorum drive, you must first add a virtual SCSI adapter to Node2, then add the shared quorum drive to the SCSI adapter. To add the SCSI adapter, select Node2, then click Edit Configuration. Click the SCSI Adapters link, then click Add SCSI Adapter >>. On the Node2 SCSI Adapter Properties page, select the Share SCSI bus for clustering check box. In the SCSI adapter ID drop-down list, select 6 (i.e., a different value than you specified for Node1). After you've selected the values, click OK.

Next, you'll add to the SCSI adapter the virtual hard drive that will serve as the shared quorum. Select Node2's Edit Configuration option, then click the Hard Disks link. The Virtual hard disk 1 section should show the virtual hard disk that was created with the VM. To add the shared virtual disk, click the Add Disk >> button, then fill out the virtual hard disk information for Virtual hard disk 2. For Virtual hard disk 2, enter the path to the shared quorum disk in the Fully qualified path to file field. This is the same path that you used for Node1. Next, in the Attachment drop-down box, select the value SCSI 0 ID 0. The completed virtual disk configuration will look like that in Figure 3.

Adding the Internal Network to Node2
The next step is to add to Node2 the second virtual NIC, which is the internal network that will connect the two cluster nodes. On the Web Administrator page, edit the Node2 configuration. Click the Network Adapters link, then click Add Network Adapter >>. In the Connected to drop-down box for Virtual network adapter 2, select Internal Network and click OK. The internal-network configuration values for Node2 will look exactly like those you entered for Node1 in Figure 4. Figure 6 shows the completed Node2 configuration. After you've configured the Node2 VM, be sure to leave Node2 powered off so that it doesn't interfere with subsequent configuration of the Node1 quorum drive.

Configuring Windows 2003 on Node1
After you've configured the VMs, the "hardware" portion of your virtual cluster is ready to go. The next step is to install and configure Windows 2003 on each cluster node. You can install Windows 2003 either from the installation CD-ROM or from an ISO image of the installation CD-ROM. To install the OS via the Windows 2003 CD-ROM, simply insert the CD-ROM into the physical system's CD-ROM/DVD drive, then power on the Node1 VM. By default, the VM is configured to access the physical drive. To avoid possible corruption of the shared quorum drive, be sure that Node2 is powered off during this time, then proceed with the Windows 2003 installation. Use the default values and name the system Node1. Be sure to add Node1 to an existing domain. At any time after the OS has been installed, you can optionally install the Virtual Machine Additions component, which provides an improved video driver.

The next steps are to configure the network and shared quorum drive that the cluster will use. To configure the network, you'll want to edit the Windows network configuration for the Node1 VM's internal and external network adapters. To configure the Windows adapters, from the Start menu select Programs, Accessories, Communications, Network Connections to open the Network Connections window. First, you'll need to reconfigure the internal network adapter to let the two clusters' nodes communicate. However, locating the NIC that's associated with the internal network isn't straightforward because the properties of both the internal and external virtual network adapters appear exactly the same in the Network Connections window. The best way I've found to identify the internal network is to open Web Administrator and select the Edit Configuration option for Node1. Then click the Network Adapters link and note the MAC address that's assigned to the internal network adapter. In my configuration, the internal virtual network adapter has a MAC address of 00-03-FF-32-91-07. To match that address to the local area connection that's shown in the Network Connections dialog box, I open a command prompt, run the command

ipconfig /all

and look for the matching value listed under the Physical address heading.

After determining which local area connection is associated with the internal and external network, I rename the connections to more meaningful names. To rename the connections, open the Network Connections folder, select the desired connection, press F2, and enter the new name. To clarify which adapter is used for the internal cluster network and which is used for external networking, I rename the connections Internal Network and External Network. Then I configure the network properties for each connection by right-clicking the connection and selecting Properties from the pop-up menu. For the external connections, I enter the fixed IP address and subnet mask Then I manually assign the IP addresses for my network's DNS and default gateway. For the internal network, I enter the fixed IP address and subnet mask and leave the gateway and DNS settings blank.

Your next step is to configure the quorum disk for Node1. To do so, from the Start Menu, right-click My Computer, then click Manage and double-click Disk Management. You should see a window similar to the one that Figure 7 shows, which displays two disks: Disk 0—Node1's system disk, and Disk 1—the shared SCSI disk that will be the cluster's quorum drive. Right-click the 47 MB unallocated space next to Disk 1 and select New Partition to start the New Partition Wizard. Accept the default selections for Partition Type and Partition Size. For the drive letter, I usually select Q: for the quorum drive. After the wizard is done, you should now have a drive C and a drive Q.

Your next step is to use the Microsoft Management Console (MMC) Active Directory Users and Computers snap-in to create a domain account, which MSCS will use. The user account that you create shouldn't be an administrator account; a standard user account will suffice. It's a good idea to give the account a meaningful name—for example, SVC-MyCluster (substitute your cluster name).

Now it's time to create the cluster on Node1. Log on in as Administrator. Then, to configure the first cluster node, from the Administrative Tools menu select Cluster Administrator. The Open Connection to Cluster dialog box will be displayed. Select Create new cluster from the drop-down list to start the New Server Cluster Wizard. Select the domain that the cluster will be in. I've named the cluster MyCluster and added it to the existing teca.local domain. (I created the teca.local domain earlier; it's hosted on Windows Server 2003 Small Business Server—SBS.)

You should now see the Select Computer dialog box, in which you enter the name of the system that will be the first cluster node. By default, the local system name (here, Node1) is displayed. Clicking Next displays the Analyzing Configuration dialog box, which verifies whether all the cluster-configuration pieces are in place. In this dialog box, you'll need to specify the quorum drive. To do so, click the Quorum button, then select Disk Q for the quorum drive. You'll see the Proposed Cluster Configuration screen, similar to the one that Figure 8 shows. After you've reviewed the displayed information and approved the proposed configuration, click Next to create the cluster.

Configuring Windows 2003 on Node2
You install Windows 2003 on Node2 by following the same procedure you used for Node1. Name the system Node2. You also use the same procedure to identify the internal network and configure the Windows network adapters for the internal and external networks. Be sure to assign the external and internal networks unique IP addresses. Use the IP address for the External IP address and for the Internal IP address. Then use Disk Management to ensure that Node2 can see the quorum drive.

After configuring the Node2 networking, you're ready to add Node2 to the cluster. To do so, go to Node1 and from the Administrative Tools menu select Cluster Administrator. After Cluster Administrator starts, you should see the cluster you created earlier. To add Node2 to the cluster, select File, New Node to start the Add Node Wizard. Proceed through the wizard to add the node as you did earlier for Node1.

You're Done!
When your virtualized cluster is up and running, you'll probably want to add some additional shared storage and set up some cluster resources, such as a sample file share. You'll also want to test various failover scenarios by connecting to the cluster, then initiating a failover by powering off either VM, or both (but not at the same time). On my test cluster, I installed Microsoft SQL Server 2005, which has a cluster-aware installation program. Doing so automatically added SQL Server to the MyCluster list of clustered resources. An application must be included in the cluster resource to be protected during a failover. However, the exact process for installing an application on a cluster varies somewhat according to the application.

I've given you the essential steps for setting up a virtualized Windows 2003 cluster. A good way to start using VMs is to set up and test server clustering or test applications in a cluster environment. By using virtualization technology such as Virtual Server 2005, you can start using clustering on your existing hardware without investing in additional expensive equipment.

Project Snapshot: How to
PROBLEM: You've heard that you can set up a Windows cluster in a virtual machine, but you don't know how to go about it. This guide gives you the essential steps for setting up a two-node, virtualized Windows Server 2003 cluster.
WHAT YOU NEED: Windows 2003, Enterprise Edition server that's configured for networking
Microsoft Virtual Server 2005
At least 50MB free disk space
DIFFICULTY: 3.5 out of 5
  1. Create the shared quorum drive.
  2. Configure the first cluster node.
  3. Add the quorum drive and internal network to the first node.
  4. Configure the second node.
  5. Add the quorum drive and internal network to the second node.
  6. Configure Windows 2003 on the nodes.

Hide comments


  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.