Sunday, January 24, 2010

Windows 2003 Microsoft Cluster on Vmware Workstation 7 Step by Step

To create a MS Cluster I followed this cookbook

1. Download Vmware Workstation 7 (current version on vmware.com) make sure it includes the Vmware tools otherwise you will have to manually download it from here
2. You need Windows 2003 Enterprise Edition (to create the cluster).
3. Install VMWare Workstation, configure a VM with these attributes :
Hardware
RAM: 320Mb
HDD0: SCSI, 4 GB
CDROM
Ethernet 1: Bridged
Ethernet 2: Host-only
Options
Advanced: Enable Template mode
4. Install Windows 2003 Enterprise Edition on it (if you are not planning to install too many things on the C: drive 7GB should be ok).
5. Post OS Installation updates: VMWare Tools, Service Pack. Link to Win2k3 SP2
6. Post OS Installation Steps
-Rename the Host-only adapter: Heartbeat Connection
-Unbind Client for Microsoft Networks and File and Printer Sharing for Microsoft Networks from this adapter
-Disable NetBIOS over TCP/IP and LMHOSTS lookup on this adapter
-Rename the Bridged connection: Public Network Connection
7. Rename this server name as DC (Domain Controller which you will need for the cluster service account). Restart.
8. Confirm everything is in place, we will use this server as Templace.
9. Shutdown server
10. Take a snapshot of the server while being off. And Clone it twice.
(make sure you select the full clone option - I had to take the snapshot prior to the clone, if not I wasn't able to clone it).
11. Let's say we have Cluster Node A and Cluster Node B. Also we have DC.
12. Don't turn on anything yet and do this :
Edit the settings of Cluster Node A and create two new SCSI hard disks into a new folder. Do not use an existing folder in which one of the VMs resides.

Disk 1: This will be the quorum disk. Make this 0.5 GB and allocate all disk space now.
Disk 2: This will be the shared data disk. Make this at least 2.0 GB and allocate all disk space now.

When adding the disks make sure to manually add the file extension .vmdk
If you don't see the extension delete and re-create adding the extension.

8. Close VMware Workstation and edit the VMware Configuration File (.VMX) file for this machine and make the following changes:

Add the following lines to create a second SCSI channel:
scsi1.present = "TRUE"
scsi1.virtualDev = "lsilogic"

Modify the additional hard drives to be attached to the new SCSI channel. Example:
scsi1:5.present = "TRUE"
scsi1:5.fileName = "I:\Cluster Shared\Quorum.vmdk"

scsi1:6.present = "TRUE"
scsi1:6.fileName = "I:\Cluster Shared\Data.vmdk"

Add the following lines to disable disk locking and caching:
disk.locking = "false"
diskLib.dataCacheMaxSize = "0"

Make sure the inverted comma is copied/pasted correctly " and not “”
I created the Clones on separate disks to help the I/O of the physical disk (I hope it helped something at least).

9. Add the same lines to the VMware Configuration of Cluster Node B.

10. Turn on the DC Server we used as a template (we can disable the option Advanced: Enable Template mode if you want).
Change the Servername, the public NIC IP Address (static and use the same IP address for the DNS), disable the HeartBeat NIC.
Add the Active Directory role, make sure to select the option to install DNS, this will also integrate DNS to AD.
This is the first DC in the network so we don't have many worries.
Done we have all on going.
In my case I chose name : Control / public static ip 192.168.1.1 / DNS 192.168.1.1

11. Start VMware Workstation and start Cluster Node A. Configure the new disks as Basic disks, format them with NTFS and assign drive letters
(Suggestion use the Q: drive letter for the Quorum disk, 500MB).
Change the Servername, the public NIC IP Address (static and use the DC IP address for the DNS), Change the HeartBeat IP Address.
In my case I chose name : Node1 / public static ip 192.168.1.10 / HeartBeat 10.0.0.1

12. Start Cluster Node B. Assign the same drive letters to the same disks.
Change the Servername, the public NIC IP Address (static and use the DC IP address for the DNS), Change the HeartBeat IP Address.
In my case I chose name : Node2 / public static ip 192.168.1.11 / HeartBeat 10.0.0.2

13. Now we have to change the SID of the 2 clones, if not we won't be able to join Node A & B to the domain.
Well to be specific, you will be able to join these servers to the domain, but when you want to login using a Domain Account you will get an error about the Domain not being SID Consistent : Link
So avoid the troubleshooting, download NewSid to change the SID of the cloned Servers. NewSid was a tool developed by sysinternals but after MS bought them, they had to shutdown NewSid. You can still find it on the web, try this place I downloaded it from there. If it's not working let me know.
You can of course use any software that let you change your Computer SID, but most of the (at the moment at least) are paid. NewSID was a great freeware tool.
Ok, if you have NewSID just generate a random SID and let the tool apply the change to your system (both Node A & B).

14. Join Node A and Node B to the domain. Reboot. Make sure you are able to join the domain.
If you are wondering about the new added disks that are shared by both servers:
When I tried to create a folder I could, but the change was not reflrected on the other node. So just leave it empty, don't create anything on them, if you did, just delete what you have done.

15. Now we are ready for the Party, Installing and configuring MSCS Windows 2003 :
I just followed this very nice guide from Microsoft


16 In case you don't want to download the file let me do a summary,
Crete a Domain Account to be used as the service account for the cluster service.
Add it to the local Administrator group on both Nodes.
On Node A - Start - Run - Cluadmin - Select create New Cluster
It will begin with a few checkings, when it ask you about how to configure it, select custom (just to make sure we select the Q: drive as the Quorum disk).
When it's time select the Q: drive for the Quorum
Next - Next - type the account name/password for the cluster service.
Type the cluster name, IP Address.
We are done, you have your cluster running.
Now Add the other Node by : right click on the cluster, New - Node - type the serve name of Node B. Next to any Window, when it comes type the password for the service account of the cluster service.
Configure the Cluster properties for the HeartBeat/Only Private communication (top priority)- Public/Mixed Communication.
We're done.

Test the cluster by moving the Cluster Group between each node.



I installed all on my computer which only has 1GB RAM Memory so if you are short of Memory, decrease the memory size of the DC to 256MB, reboot your computer,
stop any service you don't need at that very moment, close any application you don't need, kill processes, probably it will run a little slow like me but it will work.

27 comments:

6d 6a 6d 63 73 68 61 6e 65 2e 63 6f 6d 20 76 2e 35 said...

Just what I was looking for. Thanks!
Nb

Tristan said...

Your guide was spot on! Thank you for putting it out there, its very useful, and I now owe you a beer!

Ashok Kataria said...

Thanks alot my problem got resolved by changing sid. Great work !!!!

Amit Banerjee said...

Thanks a lot. adding few more lines. The main problem lies with SCSI bus channel. Check out this first. It should not use the same bus ID channel. Modify accordingly your .VMX file if u are using VMWARE..

Manhattan said...
This comment has been removed by the author.
Manhattan said...

Hi Guys,

after insterting the line codes to the vmx (point 8) the nodes didn't start anymore.
IT REPORT "Dictionary problem"
:-(

Pig Bastard said...

@Manhattan,

Have you specified the right path to the quorum and the Data disks?
These are just some examples:
scsi1:5.fileName = "I:\Cluster Shared\Quorum.vmdk"
scsi1:6.fileName = "I:\Cluster Shared\Data.vmdk"

Make sure you have the right path and you can reach them.

Jet Feng said...

on step 8, the path is correct, but since node A already has quorum and shared disk, adding the lines will make node 1 has double of them, thus cannot start.

what should i do?

Jet Feng said...

when i add nodeB into cluster, it says "the quorum disk could not be located by the cluster service"

Anonymous said...

Superb guide, a genuine thanks...

Windows-admin said...

Hello Buddy.

It was just a awesome article ... Lovely and easy way to perfomr the clustering on Vmware. But I wonder if u can help me on the disks issues which I am facing.

I have added the quorum and shared disks from my local system itslef. I am able to see them in Node A & B. But when I install cluster service, It is not taking the disks and not even asking for disks and after installation, I see all the resources are online ( 3 resources ) and no issues. But I can see here quorum as Local quorum. Not taking Q Drive. and I am not add the Node B to this cluster because of disk issues. Throwing an error Quorum disk is not found.

Russell said...

TO Windows-admin,

In your VMX config file you should already have a line for scsi0.virtualDev =

Mine was different to the one in step 8

scsi0.present = "TRUE"
scsi0.virtualDev = "lsisas1068"

check that and when adding the new line for the new scsci channel change it to the one that is already in there:

scsi1.present = "TRUE"
scsi1.virtualDev = "lsisas1068"

that sorted my problem anyway.

Cheers

Anonymous said...

Great Efforts...Thanks alot !!!

Sameer said...

Excellent Article. Very Precise and Clear.. Hats up to you.

Anonymous said...

thanks...really helpful

Anonymous said...

I get the following:

"Disk Q:" cannot be managed because it is on the same storage bus as the boot disk.

Adding node2 to cluster fails - Any ideas?

Anonymous said...

Awesome blog. Cheers!

negi said...

After formating the partition, when i join to the DC, observed that my both the disk on node A were missing so tried to format both the disk but it send the error {the format did not complete successfully}

please someone help me,

rijesh said...

Do we need to edit the settings of Node B and add the same hard disk ?(ie Quorum and Data)
I am not seeing hard disk on node B and whn i tried to add the same disks then i am getting error as the settings can not be saved.

Ramez Nabil said...

Did anyone tried these steps till the end?
As when I tried to add the second Node to the cluster, I got the below errors:

Comparing the resources between the cluster and the nodes being added...
A multi-node cluster can not be created because the quorum resource does not support adding nodes to the cluster.
A multi-node cluster can not be created because the quorum resource does not support adding nodes to the cluster.
Comparing the resources between the cluster and the nodes being added...

Thanks in advance,

Amit Verma said...

Very Usefull And Very Well Explained!! Good Job!!

SACET 2007-2009 said...

Thank you so much.It is very useful to me.Well explained good job.

mohit verma said...

hello I am not able to create new SCSI disks in a new location. there is no option while creating new disks. Can any1 help me with a screenshot if possible.

Anonymous said...

thanks great job.

kasireddy said...

Hi,
Thanks for posting this excellent article, I am able to install cluster on first node, but while adding the second node I have the below error:

"0x00138f Cluster resource not found".

Please suggest if there is any additional step to be done.

Thanks in advance,
Kasi

Anonymous said...

se puede aplicar con windows 2008?

Anonymous said...

muchas gracias!

Post a Comment