IBM Books

Administration Guide


Example - Setting up a Four-Node Partitioned Database System for Mutual Takeover

The objective for this example is to set up a four-node partitioned database system with failover support in a mutual takeover configuration. In this example, four servers are configured into two MSCS clusters. By using the mutual takeover configuration, when any of the machine fails, the database partition servers configured for that machine will fail over to the alternative machine, as configured using the MSCS software, and run as a logical node on the alternative machine.

There are two MSCS clusters in the resulting configuration. Each cluster has:

In addition, each machine has one 100X Ethernet Adapter card installed.

Each machine has the following software installed:

The resulting network configuration is as follows:
Server 1:

  • Machine name:db2test1

  • TCP/IP hostname:db2test1

  • IP Address: 9.9.9.1

    (subnet mask: 255.255.255.0

  • MSCS cluster name: ClusterA
Server 2:

  • Machine name:db2test2

  • TCP/IP hostname:db2test2

  • IP Address: 9.9.9.2

    (subnet mask: 255.255.255.0

  • MSCS cluster name: ClusterA
Server 3:

  • Machine name:db2test3

  • TCP/IP hostname:db2test3

  • IP Address: 9.9.9.3

    (subnet mask: 255.255.255.0

  • MSCS cluster name: ClusterB
Server 4:

  • Machine name:db2test4

  • TCP/IP hostname:db2test4

  • IP Address: 9.9.9.4

    (subnet mask: 255.255.255.0

  • MSCS cluster name: ClusterB

All machines in the network are configured with TCP/IP and connected to a private LAN using an Ethernet 100 T-base Hub. In the absence of a Domain Name Server (DNS), all machines have a local TCP/IP hosts file. Each hosts file contains the following entries:

   9.9.9.1	db2test1	# for Server 1
   9.9.9.2	db2test2	# for Server 2
   9.9.9.3	db2test3	# for Server 3
   9.9.9.4	db2test4	# for Server 4
   9.9.9.5	ClusterA	# for MSCS Cluster 1	
   9.9.9.6	ClusterB	# for MSCS Cluster 2
   9.9.9.7	db2tcp	# for DB2 remote client connection

Preliminary Tasks

Before you perform the following tasks, it is assumed that all four machines belong to the same domain, called DB2NTD:

  1. Create a domain account for DB2 that is a member of the local Administrators group on those machines where DB2 is going to run. Use the account for performing all tasks:

  2. Create a second domain account with the "password never expires" characteristic. This account will be associated with DB2 services:

  3. Install the MSCS feature on the machines db2test1 and db2test2:

  4. Install the MSCS feature on the machines db2test3 and db2test4:

  5. Install DB2 Extended Enterprise Edition on the machine db2test1:

  6. Install DB2 Extended Enterprise Edition on the machines db2test2, db2test3, and db2test4:

The next step is to set up the DB2MSCS.CFG file and run the DB2MSCS utility.

Run the DB2MSCS Utility

To set up the db2test1 machine, perform the following tasks:

  1. Log on as user db2nt, which belongs to the local Administrators group. The password is db2nt.

  2. Set up the DB2MSCS.CFG file:
       #
       #  DB2MSCS.CFG for one partitioned database system with
       #  multiple MSCS clusters
       DB2_INSTANCE=DB2MPP
       CLUSTER_NAME=ClusterA
       DB2_LOGON_USERNAME=db2mpp
       DB2_LOGON_PASSWORD=db2mpp
       # Group 1
       # for DB2 node 0
       GROUP_NAME=DB2NODE0
       DB2_NODE=0
       IP_NAME=IP Address for DB2
       IP_ADDRESS=9.9.9.7
       IP_SUBNET=255.255.255.0
       IP_NETWORK=Ethernet
       NETNAME_NAME=Network name for DB2
       NETNAME_VALUE=DB2WOLF
       NETNAME_DEPENDENCY=IP Address for DB2
       DISK_NAME=Disk E:
       INSTPROF_DISK=Disk E:
       #
    
       # Group 2
       # for DB2 node 1
       GROUP_NAME=DB2NODE1
       DB2_NODE=1
       DISK_NAME=Disk F:
       #   
    
       CLUSTER_NAME=ClusterB
       # Group 3
       # for DB2 node 2
       GROUP_NAME=DB2NODE2
       DB2_NODE=2
       DISK_NAME=Disk E:
    
       #
       # Group 4
       # for DB2 node 3
       GROUP_NAME=DB2NODE3
       DB2_NODE=3
       DISK_NAME=Disk F:
    

  3. Run the DB2MSCS utility as follows:
       db2mscs -f:DB2MSCS.CFG
    

  4. Log out from the db2nt account.

The final steps are to register the database drive mapping for the two MSCS clusters.

Register the Database Drive Mapping for ClusterA

To register the database drive mapping for MSCS cluster ClusterA, perform the following tasks:

  1. On the machine db2test1, log on as user db2mpp, which is the account associated with DB2 services. The password is db2mpp.

  2. To register the database drive mapping, enter the following commands:
      db2drvmp add 0 F E
     
      db2drvmp add 1 E F 
    

  3. Bring all DB2 resources offline, then bring them online.

Register the Database Drive Mapping for ClusterB

To register the database drive mapping for MSCS cluster ClusterB, perform the following tasks:

  1. On the machine db2test3, log on as user db2mpp, which is the account associated with DB2 services. The password is db2mpp.

  2. To register the database drive mapping, enter the following commands:
      db2drvmp add 2 F E
     
      db2drvmp add 3 E F 
    

  3. Bring all DB2 resources offline, then bring them online.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]

[ DB2 List of Books | Search the DB2 Books ]