You are on page 1of 15

Microsoft Virtual Labs

Creating Highly Available Services with Failover Clustering

Creating Highly Available Services with Failover Clustering

Table of Contents
Creating Highly Available Services with Failover Clustering .................................................. 1
Exercise 1 Configuring Windows 2003 Cluster Service (Join) .....................................................................................2 Exercise 2 Creating a Group for File Shares (Home Folders) .......................................................................................4 Exercise 3 Creating a Group for Print Shares ................................................................................................................8 Exercise 4 Creating Failback Policies ......................................................................................................................... 11 Exercise 5 Clustering Disks ......................................................................................................................................... 13

Creating Highly Available Services with Failover Clustering

Creating Highly Available Services with Failover Clustering


Objectives
After completing this lab, you will be better able to: Install Cluster Service. Verify Cluster service installation Create an IP Address resource Create a Network Name resource Create a File Share resource with Cluster Administrator Use CLUSTER.EXE to create shares Create an IP Address resource Create a Network Name resource Create a Print Spooler resource with Cluster Administrator Setup an Active/Active Cluster Create Failback Policies Explain the difference between a possible and a preferred owner of a group Manage shared storage Cluster shared storage 90 Minutes Node1 Node2
DC

Estimated Time to Complete This Lab Computer used in this Lab

Page 1 of 13

Creating Highly Available Services with Failover Clustering

Exercise 1 Configuring Windows 2003 Cluster Service (Join)


Scenario
In this exercise, the first node of the Cluster has already been configured. This exercise will show how the installation of Cluster Services has been improved by doing the installation from within Cluster Administrator. In Windows 2003 Enterprise Edition the Cluster Service is installed by default, but not yet configured. In this exercise, we will log onto the first node running the Cluster Service and configure the Cluster Service on the second node and allow it to join. Tasks Complete the following 2 tasks on: Node1 1. Switch to HOL169NODE1 logging in as the HOL169USER account and start Cluster Administrator
2. Add the second node

Detailed Steps a. Choose the Start menu b. Select All Programs, then Administrative Tools c. Select Cluster Administrator d. In the Open Connection to Cluster box, type HOL169CLUSTER in the Cluster or server name box.

a. Choose the File menu b. Select New c. Select Node d. In the Welcome to the Add Nodes Wizard, select Next e. In the Computer Name box, type HOL169-NODE2 f. Click the Add button so that is added g. Select Next h. At this point, it will go through and validate the configuration and connectivity. Note: Once it completes, you can expand the individual testing points to see what it was doing. Note: If you click on the View Log button, you can see that Cluster Services now create a setup log called CLCFGSRV.LOG and is located in the C:\WINDOWS\SYSTEM32\LOGFILES\CLUSTER folder on the node that was just added. Note: If you click on the Details button while highlighting the checking points, you will get a little more detail to each step. i. Once the validation is complete, click the Next Button. j. You will be prompted for the password of the Cluster Service account that is currently being used on the first node. Type the password P@sswOrd and choose Next. Note: P@sswOrd is with a capital O not a zero. k. The Next screen shows you information about the Cluster as it is configured (i.e. Name, IP Address, etc).

to the Cluster

Page 2 of 13

Creating Highly Available Services with Failover Clustering Tasks Detailed Steps l. Choose the Next button. m. This screen will run through another quick analyzing of the Cluster and also configure the Cluster Services on the second node. This will also start the Cluster Service on the second node. n. Choose the Next button. o. Choose the Finish button and you are done.

Page 3 of 13

Creating Highly Available Services with Failover Clustering

Exercise 2 Creating a Group for File Shares (Home Folders)


Scenario
In this exercise, we will show the benefits of creating file shares on a Cluster and how the administration of the shares can be kept to a minimum. When the Cluster is created the setup wizard automatically detects which disks are shared and are valid for failover. A Physical Disk resource is created to manage each LUN. Separate groups are created for each one of the disks. The first group contains a Disk R:, and it has the following directory structure on the disk: R:\home R:\home\user1 R:\home\user2 R:\home\user3 A Group is a collection of resources and is the smallest unit of failover on a cluster. Groups failover from one machine to another, not resources. All groups in a Cluster can be considered as a logical machine or instance on the network. In order for a group to be usable by clients it will normally contain a disk, a name, an IP Address, and a role. Our role for this exercise is to create a highly available File Server. Tasks Complete the following 5 tasks on: Node1 1. Create an IP Address resource Detailed Steps a. Choose the File menu b. Select New and Resource c. In the Name box, type Home Folders IP Address. This is what will display in Cluster Administrator as the name of the resource. This name is purely for internal management of the cluster and is not the name clients use to connect to the cluster. d. In the Description box, you can add a description if you like. Again, this is only for internal cluster resource identification inside of the cluster management tools. It is not visible to clients e. In the Resource Type box, select IP Address. This designates that this will be an IP Address resource. f. In the Group box, select File Shares since this will be the group we want the resource to exist. This specifies which group this resource will be associated with. g. Click Next button h. This next screen will show the Possible Owners that can own the group. Leave both nodes as Possible Owners and choose the Next button. Possible Owners is a way of saying if this resource can ever come online on a node. Traditionally all nodes have the ability to host all resources. i. The next screen is the Resource Dependencies box. This is where you would want to add a dependency that might be required in order for this resource to come online. For an IP Address resource, we do not need any dependency, so choose the Next button. Dependencies determine the start order for resources and establish the bindings. j. In the IP Address box, input the IP Address we will be using of 192.168.100.14. This is the IP address that clients will connect to and the IP address that will be registered in WINS / DNS for the file server instance.

Page 4 of 13

Creating Highly Available Services with Failover Clustering Tasks Detailed Steps k. Press the TAB key on the keyboard and the subnet mask will be detected and automatically filled in for you. l. For the Network, select the Cluster_public network m. Make sure to select Enable NetBIOS for this address so that the network name can be bound to the IP Address. n. Click Finish button, then Ok that the resource was created successfully. o. In the left hand pane select the group named File Shares p. Right mouse click on the newly created IP resource and select Bring Online. Note: You have now created an IP address that is now bound to the node and is available to external clients. This IP address is pingable.
2. Create a Network

Name Resource

Note: Now that you have an IP address available on the network, we will now create a logical server name that will be used for clients to make network connections to the file server. a. Choose the File menu b. Select New and Resource c. In the Name box, type Home Folders Network Name. This is what will display in Cluster Administrator as a resource. Again, this name is only displayed in Cluster Administrator it has no impact on clients. d. In the Description box, you can add a meaningful description if you like. This could be useful information like which business unit uses this name for connectivity. e. In the Resource Type box, select Network Name. This designates that this will be a Network Name resource. f. In the Group box, select File Shares to put it in the same group as the IP Address resource we created previously. g. Click Next button h. This next screen will show the Possible Owners that can own the group. Again, leave both nodes as Possible Owners so that failover can occur to any node and choose the Next button. i. The next screen is the Resource Dependencies box. This is where you would want to add a dependency that might be required in order for this resource to come online. For a Network Name resource, it needs to be dependent on an IP Address resource. On the left pane click on the IP address resource and then click the Add button, then choose the Next button. Note: By setting the dependency it will ensure that the IP Address resource will come online before the Network Name. It also defines that this is the IP Address that will be registered in DNS and WINS for the computer name. j. In the Name box, this is the actual name of the logical server instance users will connect to. In this box, type in HOL169FILE. k. Click the Finish button, then Ok that the resource was created successfully. l. Right mouse click on the newly created name resource and select Bring Online. Note: You have now created a Network Name resource. The machine name of HOL169FILE is now bound to the server and is available to clients. You should be able to browse this name with a Start then Run and typing \\HOL169FILE

3. Create the file share

a. Choose the File menu b. Select New and Resource c. In the Name box, type Home Folders Share.

resource

Page 5 of 13

Creating Highly Available Services with Failover Clustering Tasks Detailed Steps d. In the Description box, you can add a description if you like. e. In the Resource Type box, select File Share. This designates that this will be a File Share resource. f. In the Group box, select File Shares since this will be the group we want the resource to exist with the IP and Name previously created. g. Click Next button h. This next screen will show the Possible Owners that can own the group. Leave both nodes as Possible Owners and choose the Next button. i. The next screen is the Resource Dependencies box. This is where you would want to add a dependency that might be required in order for this resource to come online. For a File Share it should be dependent on a Physical Disk and a Network Name, so move them to the right box and choose the Next button. Remember that the Network Name is dependent on the IP. So you now have also indirectly set the File Share to be dependent on the IP address as well, because of this reason you do not need to explicitly set the File Share to be dependent on the IP. j. In the Share Name box, this is the actual name of the share the end users will connect to with the UNC. In this box, type in HOME. k. In the Path box, you must specify the exact path to where the share resides. Type in R:\HOME. l. On the Advanced Button, here is where the administration gets easier. Select Share subdirectories, what this does is take the immediate subfolder under R:\HOME and shares out all child directories automatically for you. This can come in handy for sharing out a large number of shares with a single resource and also makes administration easier, for example when users leave or join the company. Simply create the folder under R:\HOME and it will automatically share it out for you. Remove the folder and the share will disappear. You can also select the Hide Subdirectory shares option which will tag the share with a $ sign which makes the share hidden. For now, leave this unselected. Note: When setting this up, you must rely on NTFS Permissions on the drive and folders. We must have full control at the share level and then have the NTFS permissions come in to keep unauthorized users from connecting. m. Click the Finish button and then Ok. n. Right Mouse click on the newly create resource and bring it online.
4. Browse the share

a. Choose the Start Menu and select Run and type in \\HOL169FILE and press <ENTER>. You will see the shares all listed out. b. Choose the Start Menu and Run and type in R:\HOME to bring up Explorer. In this folder, create a new folder called USER4. c. Go back to the \\HOL169FILE and refresh the screen and you will see the new USER4 share dynamically created.

5. CLUSTER.EXE

commands that can be used to script creating shares

Note: File share resources can also be created with the command line utility Cluster.exe. Now that you know how to create a File Share with the Cluster Administrator tool, lets perform a file share creation from the command line. This could be handy for scripting creation of file share resources. Note: This time we will create a file share that has Share Subdirectories enabled. a. On HOL169-NODE1, open Windows Explorer then go to Disk R: and create the following folders:

R:\DEPT R:\DEPT\ACCOUNTING

Page 6 of 13

Creating Highly Available Services with Failover Clustering Tasks Detailed Steps

R:\IT

b. Run a command prompt and type the following commands:


cluster . res "Dept Shares" /create /group:"File Shares" /type:"File Share" cluster . res "Dept Shares" /priv path="R:\Dept" cluster . res "Dept Shares" /priv Sharename=DEPT cluster . res "Dept Shares" /priv security=everyone,set,F:security cluster . res "Dept Shares" /priv ShareSubDirs=1 cluster . res "Dept Shares" /AddDep:"Disk R:" cluster . res "Dept Shares" /AddDep:"Home Folders Network Name" cluster . res "Dept Shares" /Online

Note: You will now see that the share has been created. If you bring up the properties of the Dept Share resource, you will see all of the above settings. c. If you run a command prompt and type \\HOL169FILE, you will now see the Dept Share as well as the Accounting and IT Shares.

Page 7 of 13

Creating Highly Available Services with Failover Clustering

Exercise 3 Creating a Group for Print Shares


Scenario
In this exercise, we will explore the benefits of creating Printer shares on a Cluster and how the administration of the printer shares and printer driver updates can be kept to a minimum. When the Cluster Service first installs, it will create separate groups for each of the disks. The first group already has the disk (Disk S: in it, with the folder of S:\SPOOL. All groups in a Cluster can be effectively considered as an individual machine on the network. Every machine on the network has a disk, a name, an IP Address, and a role. Our role for this exercise is a File Server Tasks Complete the following 4 tasks on: Node1 1. Create an IP Address resource Detailed Steps a. Open the Cluster Administrator tool. Click Start, then Run and type CluAdmin b. Choose the File menu, Select New and Resource c. In the Name box, type Print IP Address. Again, the name of a resource is just for administrative purposes and is not exposed to external clients connecting to the print server. d. In the Resource Type box, select IP Address. This designates that this will be an IP Address. e. In the Group box, select Printers since this will be the group we want the resource to exist. f. Click Next button g. This next screen will show the Possible Owners that can own the group. Leave both nodes as Possible Owners and choose the Next button. h. For an IP Address resource, we do not need any dependency, so click Next i. In the IP Address box, input the IP Address we will be using of 192.168.100.15. j. Hit the TAB key on the keyboard and the subnet mask will be filled in for you. k. For the Network to Use, select the Cluster_public network l. Make sure to select Enable NetBIOS for this address so that the network name can be bound to the IP Address. m. Click Finish button, then Ok n. Right mouse click on the newly created resource and bring it online. Note: You now have a new IP Address bound to this node. This IP Address is pingable and can failover to another node in the cluster. This is the IP Address that will be resolved to by WINS / DNS for client connectivity.
2. Create a Network

a. Choose the File menu b. Select New and Resource c. In the Name box, type Print Network Name. d. In the Resource Type box, select Network Name. This designates that this will be a Network Name resource. e. In the Group box, select Printers since this will be the group we want the resource to exist. f. Click Next button g. This next screen will show the Possible Owners that can own the group. Leave

Name Resource

Page 8 of 13

Creating Highly Available Services with Failover Clustering Tasks Detailed Steps both nodes as Possible Owners and choose the Next button. h. The next screen is the Resource Dependencies box. A Network Name resource needs to dependent on an IP Address resource, so move the IP Address to the right box and choose the Next button. i. In the Name box, this is the actual name of the server the users will connect to. In this box, type in HOL169PRINT. j. Click the Finish button, then Ok k. Right mouse click on the newly created resource and bring it online. Note: You now have a new NetBIOS name bound to this node, this is the machine name that external clients will use when connecting to the server. This name will be registered in WINS and DNS using the IP Address it is dependent on, which you created in the previous step.
3. Create a Print

a. Choose the File Menu, then select New and Resource b. In the Name Box, type Print Spooler. c. In the Resource Type box, select Print Spooler. This designates that this will be a Print Spooler resource. d. In the Group box, select Printers since this will be the group we want the resource to exist. e. Click Next button f. This next screen will show the Possible Owners that can own the group. Leave both nodes as Possible Owners and choose the Next button. g. The next screen is the Resource Dependencies box. This is where you would want to add a dependency that might be required in order for this resource to come online. A Spooler resource needs to be dependent on a Network Name resource which establishes how clients will connect to this spooler and it needs a Disk resource which establishes where print jobs should be spooled and drivers stored.Select Disk S:, Print IP Address, and Print Network Name and add them to the Resource dependencies. h. In the next screen, it will show you the location of S:\SPOOL which is where the print jobs will be spooled when clients print. i. Click the Finish button, then Ok j. Right mouse click on the newly created resource and bring it online. Note: You have now finished creating a highly available print server! You have the IP Address established that clients will use, the machine name clients will connect to, and have a spooler resource that will handle print jobs. The only thing left is to create some print queues to use.

Spooler resource

4. Create Printers

Note: This is where some of the burden of printer installs on a Cluster Server in previous versions has been eased. In previous versions of Windows it required drivers being manually replicated. Now, with Windows 2003 Cluster, it is all automatic. Note: Creating printers on a clustered print server is slightly different from a standalone server. Instead of using the local control panel Printers and Faxes, you need to make a remote connection to the print cluster. a. From the Start menu, click Run and type \\HOL169PRINT. b. Double mouse click on Printers and Faxes. c. Double mouse click on Add Printer to bring up the Add Printer Wizard. d. Click the Next button e. Select Create a new port and Standard TCP/IP Port and Next to bring you into the Add Port Wizard. Note: Only Cluster Aware port monitors are supported on

Page 9 of 13

Creating Highly Available Services with Failover Clustering Tasks Detailed Steps failover clusters. f. Click the Next button. g. Type in the IP Address of 192.168.100.25 and Next h. Leave the default selection of Generic Network Card and click Next i. Select Finish button j. Now we are prompted to install a printer. Go ahead and select the Agfa as the Manufacturer and AGFA-AccuSet v52.3 Printer and Next button. k. Leave the Printer name as the default selected and choose Next button l. Leave the Share name as Agfa-Acc and click Next m. The Location and Comment boxes are for information displayed when browsing the printer. You can put something in if like and choose Next button. n. Select No for a test page as the physical printer does not actually exist for this lab, then click Next button. o. Click the Finish button. p. When prompted for the Windows Server 2003 CD-ROM, Then type in C:\Labs\PrinterDriver, click Ok. q. From the Start menu, type \\HOL169PRINT and you will now see the printer. r. By going to Drive S: in Explorer, you will now see a folder called S:\PrinterDrivers that has the subfolders of \W32X86\ \3. This is where the printer drivers are actually copied during the installation. s. Looking locally on Drive C:, you will now see the folder C:\WINDOWS\SYSTEM32\SPOOL\DRIVERS\<guid>\DRIVERS\\W32X86\3 which is the location that we copy the printer drivers to so that the clients can gain access to the files. If you go to the node that does not currently hold the Print Spooler resource, you will see that the local directory does not contain the print driver files. Note: In Cluster Administrator, right mouse click on the Printers Group and select Move Group to move the group to the other node. Now check this same local directory and you will see the drivers are now there. This is because there is a flag that is marked for any printers newly added or updated. When the node brings the Spooler resource online, it checks for this flag and copies down the appropriate files to the local machine if it does not have them. So clustering takes care of replicating all the printer drivers to all the nodes in the cluster for you.

Page 10 of 13

Creating Highly Available Services with Failover Clustering

Exercise 4 Creating Failback Policies


Scenario
In this exercise, we will demonstrate more advanced topics on how to set up Failback policies so that each node in the Cluster has a group assigned to it, referred to as an Active/Active configuration. This is beneficial in the case of a File and Print Cluster (or Cluster with two print spoolers). The reason for this is so that you can manually distribute the load out across multiple nodes in the cluster to take better advantage of available resources. Failover Clustering has the ability to define a specific node in the cluster as the preferred node that is to own a particular group. If for any reason this node fails or goes offline, you can set the Cluster service to automatically move these groups back to the node that you want to. This is useful in statically load-balancing the nodes in your cluster. This is referred to as Failover and Failback policies. The first thing to differentiate is between what a possible owner and a preferred owner is. Possible Owner defines whether a resource is ever able to failover to a specific node. Use extreme caution in defining Possible Owners because defining a possible owner for a single resource will affect the failover for the entire group. This is defined under the properties of the individual resources. If you bring up the properties of a group, you will see a Preferred Owners box. As a default, this is left blank. When you configure a group to automatically failback to the preferred node, you specify whether you want the group to failback as soon as the preferred node is available or to failback only during specific hours that you define. This option is useful if you want the failback to occur after peak business hours, or if you want to make sure the preferred node is able to support the group when it does come back online. The Preferred Owner of a group must be specified for failback to occur. The preferred owner is the node that one configures to (under normal operating circumstances) to host the group. Furthermore, on a resource level, the resource must be configured to have both nodes as "Possible Owners" for the resource to failover. Tasks Complete the following task on: Node1 1. Define Preferred Owners Detailed Steps a. In Cluster Administrator, right mouse click on the File Shares group and choose Properties. Note: This is on the Group itself on the left hand pane. b. On the General tab, select the Modify button. c. Add HOL169-NODE1 only as the Preferred Owner d. On the Failback tab, select Allow Failback and Immediately. Then click OK Note: Now that you have established that Node 1 should be the primary owner of the file shares, lets set Node 2 to be the primary owner of the printers. e. In Cluster Administrator, now right mouse click on the Printers Group and again choose Properties. f. On the General tab, select the Modify button. g. Add HOL169-NODE2 only as the Preferred Owner. h. On the Failback tab, set Allow Failback and Immediately. Then click OK. Complete the following task on: Node1 and Node2 2. Test Preferred Owner Note: Node 1 is now the preferred owned of file shares and Node 2 is the preferred owner of printers. Lets try failing over some disks to view the behavior. a. Switch to HOL169-NODE1 and open Cluster Administrator. Select Active Groups under HOL169-NODE1 node, notice that there is no printer in the right pane. Select Active Group under HOL169-NODE2, notice that there is printers entry in the right pane. b. In the left column, right mouse click on HOL169-NODE2 and choose Stop

Page 11 of 13

Creating Highly Available Services with Failover Clustering Tasks settings Detailed Steps Cluster Service. c. All groups would now be owned by HOL169-NODE1. d. Select Active Group under HOL169-NODE1 node, notice that the printer entry is now listed on the right pane. e. Once the Cluster Service has stopped on HOL169-NODE2 (designated by the red x), right mouse click it again and select Start Cluster Service. f. Notice that when HOL169-NODE2 starts up, the Printers Group is immediately moved over and now resides on that node. g. Switch to HOL169-NODE2 and open Cluster Administrator. h. Select Active Groups under HOL169-NODE1 node, notice that there are two entries in the right pane, Cluster Group and File Shares i. In the left column, right mouse click on HOL169-NODE1 and choose Stop Cluster Service. j. All groups would now be owned by HOL169-NODE2. k. You can select the Active Groups under HOL169-NODE2 Node, notice that the Cluster Group and File Shares entries have moved to the HOL169-NODE2 Active Groups. l. Once the Cluster Service has stopped on HOL169-NODE1 (designated by the red x), right mouse click it again and select Start Cluster Service. m. Notice that when HOL169-NODE1 starts up, the File Shares Group are immediately moved over and now reside on that node. Note: This setting only takes effect when the Cluster Service starts on the particular node. If you were to manually move the File shares Group to HOL169-NODE2, it will stay there and will not automatically moved back to HOL169-NODE1. This is because Failback policies ONLY come into play when the Cluster Service on the particular node starts.

Page 12 of 13

Creating Highly Available Services with Failover Clustering

Exercise 5 Clustering Disks


Scenario
This is a bonus extra lab suggestion for people interested in going beyond the base lab. This lab will not contain step-by step instructions, but is merely a suggestion for people interested in exploring clustering further. If you would like to play with clustering some more on your own free time you may find this lab suggestion interesting. Tasks Complete the following task on: Node1
1. Clustering Disks

Detailed Steps a. On Node1, open up DiskMgmt.msc. You will notice there is a LUN that has free space listed and has not been clustered. Go ahead and partition and format the disk. Remember that all clustered disks must be Basic disks and MBR. Then go ahead and assign the disk a drive letter. b. Open up Windows Explorer and view the new disk, go ahead and create a test file on it. Once you have the disk partitioned and ready for cluster use open up Cluster Administrator. Create a new resource of type Physical Disk using the same steps as in the previous labs in either one of the existing groups or you could create a new group. Bring the disk online and fail it over to Node 2. You will see that the same drive letter will be replicated to Node 2. Also note how only 1 node ever has access to a disk at any given time.

Page 13 of 13

You might also like