Nonstop Database, HiRDB Version 9 System Operation Guide

[Contents][Index][Back][Next]

26.3.4 HiRDB preparations

Executor: HiRDB administrator

This subsection explains how to prepare a system for HiRDB.

Organization of this subsection
(1) Conditions and notes
(2) Preparing a shared disk unit
(3) Creating HiRDB system definitions
(4) Creating RDAREAs
(5) Defining global buffers
(6) Using audit trail files
(7) Notes on using the NetBackup linkage facility

(1) Conditions and notes

(a) Information needed in the primary and secondary systems

Make sure that the following information is the same in both the primary and secondary systems:

(b) Notes concerning environment settings

(2) Preparing a shared disk unit

There must be an external hard disk that can be shared between the primary system and the secondary system. This hard disk is called a shared disk unit.

(a) Shared disk allocation

The following figure shows shared disk allocation.

Figure 26-61 Shared disk allocation

[Figure]

Explanation
A shared disk is allocated to each unit because system switchovers occur on a unit-by-unit basis.

Create the following HiRDB file system areas on the shared disk unit:

Notes
  • Set up these HiRDB file system areas so that the HiRDBs of both the primary system and the secondary system can reference the shared disk unit by using the same path name.
  • The shared disk on which HiRDB file system areas for shared RDAREAs are created must be activated in the write mode from all units. For this reason, the disk must not be deactivated or activated in conjunction with a system switchover.
  • On a shared disk, use character special files instead of regular files. If a system switchover occurs when regular files are in a status that does not apply to shared disks (for example, data remains in the operating system cache even though HiRDB finished writing it to the target files), any updates made to the files might be lost. Note that if the operating system can guarantee the integrity of the data in regular files (journal file systems) even if a system switchover occurs, the following files can be used on a shared disk:
    [Figure] Unload log files that are unloaded using the pdlogunld command or the automatic log unloading facility
    [Figure] Backup files that are acquired using the database copy utility (pdcopy)
    [Figure] Unload data files that are created using the database reorganization utility (pdrorg)
(b) Shared disk access control

If the system switchover source and target both attempt to access the shared disk at the same time while the system switchover facility is being used, the database might become corrupted. For this reason, accesses from the system to the shared disk must be controlled. Shared disk access control is performed by the cluster software or HiRDB.

Normally, the method described in Shared disk access control by the cluster software is used to perform access control on the shared disk. To use the method described in Shared disk access control by HiRDB, you must have HA Monitor 01-08 or later.

Shared disk access control by cluster software
The cluster software performs access control on the shared disk. It exercises control in such a manner that the running system is active and the standby and stopped systems are inactive, so that only the running system can access the shared disk. The following figure shows shared disk access control by the cluster software.

Figure 26-62 Shared disk access control by the cluster software

[Figure]
Explanation
An inactive system cannot access the shared disk. Only the running system can access the shared disk.
For details about the shared disk switching method (between active and inactive), see the cluster software documentation.
If you are using HA Monitor, you must specify the disk operand in the servers definition statement for HA Monitor.

Shared disk access control by HiRDB
To use HiRDB to perform access control on the shared disk, you must have HA Monitor 01-08 or later.
HiRDB can perform access control on the shared disk. In this case, shared disk switching (between active and inactive) is not performed. System switchovers take place in the following sequence:
  1. A failure that triggers a system switchover occurs.
  2. HiRDB confirms that all processes (HiRDB processes) have terminated in the source system.
  3. The system switchover takes place.
  4. The target system starts accessing the shared disk.
The following figure shows the shared disk access control that is provided by HiRDB.

Figure 26-63 Shared disk access control by HiRDB

[Figure]

(3) Creating HiRDB system definitions

(a) Configuring HiRDB system definition files

Use the same HiRDB system definitions in the primary system and the secondary system. Create the HiRDB system definitions for the primary system, and then copy those HiRDB system definitions to the secondary system. The following figures show configuration examples of HiRDB system definition files for a HiRDB single server configuration and a HiRDB parallel server configuration.

Figure 26-64 Configuration example of HiRDB system definition files when using the standby system switchover facility (for a HiRDB single server configuration)

[Figure]

Figure 26-65 Configuration example of HiRDB system definition files when using the standby system switchover facility (for a HiRDB parallel server configuration)

[Figure]

(b) HiRDB system definition operands to be set up when user server hot standby is used

This subsection explains the HiRDB system definition operands that you need to set up when user server hot standby is used. The following table lists the related operands.

Table 26-16 HiRDB system definition operands to be set up when user server hot standby is used

Operand Explanation and notes
pd_ha Specifies to use the system switchover facility.
pd_ha_unit Do not specify this operand if a system switchover facility is used on the unit.
If the system includes a unit to which you do not want to apply the system switchover facility, or it includes a recovery-unnecessary front-end server unit, specify nouse for the pd_ha_unit operand of the unit control information definition of that unit.
pd_ha_acttype Specifies whether to use the system switchover facility in the monitor mode or the server mode.
monitor: Operate the system switchover facility in the monitor mode.
server: Operate the system switchover facility in the server mode.
When you use user server hot standby, specify server in this operand.
pd_ha_server_process_standby Specifies whether to use user server hot standby.
Y: Use user server hot standby.
N: Do not use user server hot standby.
pd_ha_transaction
pd_ha_trn_queuing_wait_time
pd_ha_trn_restart_retry_time

  • Specify these operands when you use the transaction queuing facility.
  • If you specify queuing in the pd_ha_transaction operand and the maximum number of concurrent connections (value of the pd_max_users operand) is exceeded, the HiRDB client will attempt to re-establish a connection to the HiRDB server for only the amount of time that is equal to pd_ha_trn_queuing_wait_time + pd_ha_trn_restart_retry_time.
pd_ha_switch_timeout This operand can be specified when the server mode is used. It is ignored in the monitor mode, even if it is specified.
This operand specifies whether to perform a system switchover without waiting for HiRDB termination processing when termination processing of HiRDB (or a unit for a HiRDB parallel server configuration) during the system switchover exceeds the server failure monitoring time. Server failure monitoring time refers to the time specified in the patrol operand of HA Monitor or Hitachi HA Toolkit Extension.
For details about the patrol operand of HA Monitor, see the manual High-Availability System Monitoring Facility. For details about the patrol operand of Hitachi HA Toolkit Extension, see the manual Hitachi HA Toolkit.
Y: Switch systems without waiting for HiRDB termination processing when HiRDB termination processing during a system switchover exceeds the server failure monitoring time.
N: Do not switch systems until all termination processing that occurs in HiRDB during a system switchover is finished.
pd_ha_prc_cleanup_check Specifies whether to place system switchover processing on hold until the server processes have terminated. For details, see 26.3.4(2)(b) Shared disk access control.
pd_mode_conf This operand is related to HiRDB (or unit) startup. Specify a value as explained below.
If you use user server hot standby, specify one of the following:
  • MANUAL2 if switch is specified in the switchtype operand of the servers definition of HA Monitor or Hitachi HA Toolkit Extension.
  • MANUAL1 if restart or manual is specified in the switchtype operand of the servers definition of HA Monitor or Hitachi HA Toolkit Extension.
pd_hostname Specifies the standard host name of the primary system.
pdunit -x Specifies the host name of the primary system. If you are using the standby-less system switchover facility, specify the unit's host name.
-u Specifies the unit identifier.
-d Specifies the HiRDB directory name. If you are using a multi-standby configuration, specify the same directory name in the primary system and all secondary systems.
-c Specifies the host name of the secondary system. Specify this option if IP addresses are not inherited after a system switchover.
-p Specifies a HiRDB port number.
-s Specifies a scheduler port number.
-t Specifies a transaction server port number.
pd_service_port Exercise care when specifying this operand in a server machine configuration that includes multiple units (including a mutual system switchover configuration). For such configurations (including a mutual system switchover configuration), use this operand to specify a separate port number for each unit in its unit control information definition.
If either of the following is specified, system switchovers to one of the units fail:
  • The pd_service_port operand of the system common definition is specified (when the pd_service_port operand of the unit control information definition is not specified).
  • A port number that is specified in the pd_service_port operand of another unit control information definition is specified in the pd_service_port operand of the unit control information definition.
(c) HiRDB system definition operands to be set up when the rapid system switchover facility is used

This subsection explains the HiRDB system definition operands that you need to set up when the rapid system switchover facility is used. The following table lists the related operands.

Table 26-17 HiRDB system definition operands to be set up when the rapid system switchover facility is used

Operand Explanation and Notes
pd_ha Specifies to use the system switchover facility.
pd_ha_ipaddr_inherit Specifies whether to inherit IP addresses after a system switchover. Specify N for units using the rapid system switchover facility.
Y: Inherit IP addresses.
N: Do not inherit IP addresses.
pd_ha_unit Do not specify this operand if a system switchover facility is used on the unit.
If the system includes a unit to which you do not want to apply the system switchover facility, or it includes a recovery-unnecessary front-end server unit, specify nouse for the pd_ha_unit operand of the unit control information definition of that unit.
pd_ha_acttype Specifies whether to use the system switchover facility in the monitor mode or the server mode.
monitor: Operate the system switchover facility in the monitor mode.
server: Operate the system switchover facility in the server mode.
When you use the rapid system switchover facility, specify server in this operand.
pd_ha_agent When you use the rapid system switchover facility, specify standbyunit in this operand.
pd_ha_transaction
pd_ha_trn_queuing_wait_time
pd_ha_trn_restart_retry_time

  • Specify these operands when you use the transaction queuing facility.
  • If you specify queuing in the pd_ha_transaction operand and the maximum number of concurrent connections (value of the pd_max_users operand) is exceeded, the HiRDB client will attempt to re-establish a connection to the HiRDB server for only the amount of time that is equal to pd_ha_trn_queuing_wait_time + pd_ha_trn_restart_retry_time.
pd_ha_switch_timeout This operand can be specified when the server mode is used. It is ignored in the monitor mode, even if it is specified.
This operand specifies whether to perform a system switchover without waiting for HiRDB termination processing when termination processing of HiRDB (or a unit for a HiRDB parallel server configuration) during the system switchover exceeds the server failure monitoring time. Server failure monitoring time refers to the time specified in the patrol operand of HA Monitor or Hitachi HA Toolkit Extension.
For details about the patrol operand of HA Monitor, see the manual High-Availability System Monitoring Facility. For details about the patrol operand of Hitachi HA Toolkit Extension, see the manual Hitachi HA Toolkit.
Y: Switch systems without waiting for HiRDB termination processing when HiRDB termination processing during a system switchover exceeds the server failure monitoring time.
N: Do not switch systems until all termination processing that occurs in HiRDB during a system switchover is finished.
pd_ha_prc_cleanup_check Specifies whether to place system switchover processing on hold until the server processes have terminated. For details, see 26.3.4(2)(b) Shared disk access control.
pd_mode_conf This operand is related to HiRDB (or unit) startup.Specify a value as explained below.
If you use the rapid system switchover facility, specify one of the following:
  • MANUAL2 if switch is specified in the switchtype operand of the servers definition of HA Monitor or Hitachi HA Toolkit Extension.
  • MANUAL1 if restart or manual is specified in the switchtype operand of the servers definition of HA Monitor or Hitachi HA Toolkit Extension.
pd_hostname Specifies the standard host name of the primary system.
pdunit -x Specifies the host name of the primary system.
-u Specifies the unit identifier.
-d Specifies the HiRDB directory name.
-c Specifies the host name of the secondary system. Specify this option if IP addresses are not inherited after a system switchover.
-p Specifies a HiRDB port number.
-s Specifies a scheduler port number.
-t Specifies a transaction server port number.
pd_service_port Exercise care when specifying this operand in a server machine configuration that includes multiple units (including a mutual system switchover configuration). For such configurations (including a mutual system switchover configuration), use this operand to specify a separate port number for each unit in its unit control information definition.
If either of the following is specified, system switchovers to one of the units fail:
  • The pd_service_port operand of the system common definition is specified (when the pd_service_port operand of the unit control information definition is not specified).
  • A port number that is specified in the pd_service_port operand of another unit control information definition is specified in the pd_service_port operand of the unit control information definition.
pd_ha_mgr_rerun If notwait is specified for this operand, HiRDB does not wait for a startup processing completion notification from each unit when the system manager unit is switched (during startup processing at the switching-destination system). Therefore, the system manager unit can be switched even when there is a stopped unit.
For details about how to use this option, see 26.7.9 Notes on system switchovers for the system manager unit.

(4) Creating RDAREAs

You define RDAREAs in HiRDB file system areas for RDAREAs on the shared disk. This subsection provides definition examples of creating user RDAREAs and system RDAREAs in HiRDB file system areas that are created on different shared disks. It also explains these concepts based on the system configuration examples in the following figures.

Figure 26-66 HiRDB single server configuration example

[Figure]

[Figure] Example create rdarea statement specification

 
create rdarea SMAST for masterdirectory                   1
  file name "/sds0111/srd01" initial 10 segments;
create rdarea SDIR for datadirectory                      2
  file name "/sds0112/srd02" initial 5 segments;
create rdarea SDIC for datadictionary                     3
  file name "/sds0113/srd03" initial 20 segments;
create rdarea SUSR01 for user used by PUBLIC              4
  file name "/sds0121/srd04" initial 500 segments;
create rdarea SUSR02 for user used by PUBLIC              5
  file name "/sds0131/srd05" initial 500 segments;
 

Explanation
  1. Creates the SMAST master directory RDAREA in the HiRDB file system area on shared disk A.
  2. Creates the SDIR data directory RDAREA in the HiRDB file system area on shared disk A.
  3. Creates the SDIC data dictionary RDAREA in the HiRDB file system area on shared disk A.
  4. Creates the SUSR01 user RDAREA in the HiRDB file system area on shared disk B.
  5. Creates the SUSR02 user RDAREA in the HiRDB file system area on shared disk C.

    Figure 26-67 HiRDB parallel server configuration example

    [Figure]

[Figure] Example create rdarea statement specification

 
create rdarea PMAST for masterdirectory                      1
    server name DIC file name "/dic0111/prd01"
    initial 10 segments;
create rdarea PDIR for datadirectory                         2
    server name DIC file name "/dic0112/prd02"
    initial 5 segments;
create rdarea PDIC for datadictionary                        3
    server name DIC file name "/dic0113/prd03"
    initial 20 segments;
create rdarea PUSR01 for user used by PUBLIC                 4
    server name BACK01 file name "/back0121/prd04"
    initial 500 segments;
create rdarea PUSR02 for user used by PUBLIC                 5
    server name BACK02 file name "/back0231/prd05"
    initial 500 segments;
 

Explanation
  1. Creates the PMAST master directory RDAREA in the HiRDB file system area on shared disk A.
  2. Creates the PDIR data directory RDAREA in the HiRDB file system area on shared disk A.
  3. Creates the PDIC data dictionary RDAREA in the HiRDB file system area on shared disk A.
  4. Creates the PUSR01 user RDAREA in the HiRDB file system area on shared disk B.
  5. Creates the PUSR02 user RDAREA in the HiRDB file system area on shared disk C.

(5) Defining global buffers

To allocate global buffers to the RDAREAS that you created above, perform the steps in Global buffer allocation procedures in the HiRDB Version 9 Installation and Design Guide.

(6) Using audit trail files

Executor: HiRDB administrator or auditor

The HiRDB administrator creates audit trail files on a shared disk. The HiRDB administrator and the auditor can use the audit trail files on the shared disk.

(a) Creating audit trail files

The HiRDB administrator creates audit trail files on a shared disk.

(b) Using audit trail files

When a system switchover occurs, HiRDB records monitored events in an audit trail file on the shared disk. For details about operations involving audit trail files related to the recording of monitored events, see 24.6 Operation of audit trail files.

(c) Collecting audit trails

When a system switchover occurs, the way the audit trail collection status is inherited depends on whether the switched unit stops. If the system at the switching destination restarts, the status before the system switchover occurred is inherited. If the system at the switching destination starts normally, the specification in the pd_audit operand is used.

(d) Executing the pdload command

The HiRDB administrator executes the pdload command using the audit trail files as input information (certification is done by the auditor). However, if a factor such as an error caused a system switchover, HiRDB will not have correctly collected the audited events that occurred immediately before the system switchover. For this reason, even if the pdload command is executed, it might not be possible to collect the data that existed immediately before the system switchover.

(7) Notes on using the NetBackup linkage facility

When you use the NetBackup linkage facility in a system switchover configuration, the environment assignments and operations described below are necessary if the recovery is carried out on a NetBackup client different from the NetBackup client from which a backup was acquired. Apply these environment assignments and operations only when JP1/VERITAS NetBackup 5.0 or later is being used.