Hitachi

JP1 Version 12 JP1/Automatic Job Management System 3 Configuration Guide


23.5.2 Advanced setting up an embedded database (on the secondary node)

This subsection describes the procedures for installing an embedded database, setting up the environment for operating the embedded database, and setting up the embedded database on the secondary node in a cluster configuration.

Organization of this subsection

(1) Installing an embedded database

To install an embedded database, you must perform the procedure described in 23.4.1(1) Installing an embedded database. If you plan to install the embedded database on the secondary node in a cluster configuration, read the following notes before starting the installation.

Cautionary notes:
  • When you install the embedded database, install it on the local disk on the secondary node. Specify the same drive name and folder name for the local disks on the primary and secondary nodes.

  • If physical host and multiple logical hosts reside on a single machine and use different embedded databases, specify unique setup identifiers to avoid duplication conflicts.

Also check the detailed information about installation. For details about installation, see 23.4.1(1) Installing an embedded database.

(2) Setting up the embedded database environment

To set up the embedded database environment:

  1. Stop services.

    Stop all services that access the scheduler database. Such services include the JP1/AJS3 on the physical host and all logical hosts.

  2. In UNIX, delete the environment setting information from the shared memory.

    Use the ajsshmdel command to delete the environment setting information in the shared memory.

    ajsshmdel >/dev/null 2>&1
  3. To set up an environment in JP1/AJS3 10-00 or later, copy the embedded database settings file from the primary node to the secondary node.

    Copy the following embedded database settings file from the primary node to the secondary node.

    • In Windows:

      embedded-database-practical-directory\conf\ajsdbst\ajsembdbsetup-identifier.conf

    • In UNIX:

      embedded-database-practical-directory/conf/ajsdbst/ajsembdbsetup-identifier.conf

  4. Execute a command to set up the embedded database environment.

    Use the ajsembdbbuild command to set up the embedded database.

    When executed, the ajsembdbbuild command performs the following operations:

    • Creates the definition information of the embedded database.

    • Creates the embedded database work area.

    When you execute the ajsembdbbuild command on the secondary node, specify the -f option instead of the -r option. For other arguments, specify the same settings that you specified for the primary node.

For details about the ajsembdbbuild command, see ajsembdbbuild in 2. Commands Used during Setup in the manual JP1/Automatic Job Management System 3 Command Reference.

Supplementary note:

You cannot set up an environment that duplexes the system file, but does not use the system log (the combination of items in Table 23-2 and Table 23-3 is 8-A, 10-A, or 12-A).

Cautionary notes:
  • In the hosts file or in the DNS, you must register the names of both the primary node physical and logical hosts on which an embedded database environment is set up.

  • A host name registered in the jp1hosts or jp1hosts2 definition file cannot be used as the name of a host on which an embedded database environment will be set up.

  • Do not use an alias for the name of a host on which an embedded database environment will be set up.

  • To configure an embedded-database environment on a host, set the host name by using 1 to 63 bytes for a physical host or by using 1 to 32 bytes for a logical host.

Examples of executing the command ajsembdbbuild when setting up a large-scale embedded database environment are shown in subsections (a) and (b) below. The examples also provide the combination of the item numbers indicated in Table 23-2 and Table 23-3.

(a) For Windows

■ If the JP1/AJS3 version is 10-00 or later

Execute the following command:

ajsembdbbuild -conf embedded-database-settings-file-name
Cautionary notes:
  • For embedded-database-settings-file-name, specify the file name you copied in step 3 in (2) Setting up the embedded database environment.

  • If you execute this command, the embedded database is configured with the same configuration as that when the option was specified for the ajsembdbbuild command on the executing host. Before executing the ajsembdbbuild command, create the following directories, which have already been specified on the executing host.

    - Unload log file creation directory

    - Embedded database work area directory

    - Embedded database installation directory

    Note that the unload log file creation directory also needs to be created on the standby host if you specified a directory on the local disk when setting up the executing host.

■ If the JP1/AJS3 version is earlier than 10-00

The specification examples in this subsection assume that the following values are set. Create the following directories before executing the ajsembdbbuild command:

  • Data area creation directory: l:\EmbDB\RDArea

  • System file area creation directory 1: m:\EmbDB\SYSArea1

  • System file area creation directory 2: n:\EmbDB\SYSArea2

  • Unload log file creation directory: o:\EmbDB\Unload_Log

  • Embedded database work area directory: p:\EmbDB\WorkArea

  • Embedded database installation directory: c:\Program Files#1\HITACHI\JP1AJS2\embdb\_JFA

  • Scheduler service name: AJSROOT4

  • Embedded database port number: 22230

  • Embedded database setup identifier: _JFA

  • Name of the primary node physical host#2: physical_host

  • Logical host name: logical_host

  • If the system files are not duplicated and the system log is not used#3 (combination 11-A in Table 23-2 and Table 23-3):

    ajsembdbbuild -l 
    -d "l:\EmbDB\RDArea,m:\EmbDB\SYSArea1"
    -ld p:\EmbDB\WorkArea -i "c:\Program Files\HITACHI\JP1AJS2\embdb\_JFA"
    -p 22230 -id _JFA -f -mh logical_host -eh physical_host
  • If the system files are not duplicated and unloading is used (combination 11-B in Table 23-2 and Table 23-3):

    ajsembdbbuild -l 
    -d "l:\EmbDB\RDArea,m:\EmbDB\SYSArea1" 
    -ld p:\EmbDB\WorkArea -bs -bl o:\EmbDB\Unload_Log 
    -i "c:\Program Files\HITACHI\JP1AJS2\embdb\_JFA" 
    -p 22230 -id _JFA 
    -f -mh logical_host -eh physical_host
  • If the system files are duplicated and unloading is used (combination 12-B in Table 23-2 and Table 23-3):

    ajsembdbbuild -l 
    -d "l:\EmbDB\RDArea,m:\EmbDB\SYSArea1,
    n:\EmbDB\SYSArea2" -ld p:\EmbDB\WorkArea -br 
    -bl o:\EmbDB\Unload_Log 
    -i "c:\Program Files\HITACHI\JP1AJS2\embdb\_JFA" 
    -p 22230 -id _JFA -f -mh logical_host -eh physical_host
#1:

For 64-bit versions of Windows, replace Program Files with Program Files (x86).

#2:

When setting up the environment of the embedded database on the secondary node, specify the name of the primary node physical host for the -eh option of the ajsembdbbuild command.

#3:

To use the backup enhancement function, specify the -b option for the ajsembdbbuild command.

(b) For UNIX

■ If the JP1/AJS3 version is 10-00 or later

Execute the following command:

ajsembdbbuild -conf embedded-database-settings-file-name
Cautionary notes:
  • For embedded-database-settings-file-name, specify the file name you copied in step 3 in (2) Setting up the embedded database environment.

  • If you execute this command, the embedded database is configured with the same configuration as that when the option was specified for the ajsembdbbuild command on the executing host. Before executing the ajsembdbbuild command, create the following directories, which have already been specified on the executing host.

    - Unload log file creation directory

    - Embedded database work area directory

    - Embedded database installation directory

    Note that the unload log file creation directory also needs to be created on the standby host if you specified a directory on the local disk when setting up the executing host.

■ If the JP1/AJS3 version is earlier than 10-00

The specification examples in this subsection assume that the following values are set. Create the following directories before executing the ajsembdbbuild command:

  • Unload log file creation directory: /Unload_Log_JFA

  • Embedded database work area directory: /WorkArea_JFA

  • Embedded database installation directory: /opt/jp1ajs2/embdb/_JFA

  • Scheduler service name: AJSROOT4

  • Embedded database port number: 22230

  • Embedded database setup identifier: _JFA

  • Name of the primary node physical host#: physical_host

  • Logical host name: logical_host

  • Data area creation directory: /share1/RDArea_JFA

  • System area creation directory: /share2/SYSArea_JFA

  • System area creation directory: /share3/SYSArea_JFA

#:

When setting up the environment of the embedded database on the secondary node, specify the name of the primary node physical host for the -eh option of the ajsembdbbuild command.

  • If the system files are not duplicated and the system log is not used# (combination 11-A in Table 23-2 and Table 23-3):

    ajsembdbbuild -l 
    -d "/share1/RDArea_JFA,/share2/SYSArea_JFA" 
    -ld /WorkArea_JFA -i /opt/jp1ajs2/embdb/_JFA -p 22230 
    -id _JFA -f -mh logical_host -eh physical_host
  • If the system files are not duplicated and unloading is used (combination 11-B in Table 23-2 and Table 23-3):

    ajsembdbbuild -l 
    -d "/share1/RDArea_JFA,/share2/SYSArea_JFA" 
    -ld /WorkArea_JFA -bs -bl /Unload_Log_JFA 
    -i /opt/jp1ajs2/embdb/_JFA -p 22230 -id _JFA 
    -f -mh logical_host -eh physical_host
  • If the system files are duplicated and unloading is used (combination 12-B in Table 23-2 and Table 23-3):

    ajsembdbbuild -l 
    -d "/share1/RDArea_JFA,/share2/SYSArea_JFA,
    /share3/SYSArea_JFA" 
    -ld /WorkArea_JFA -br -bl /Unload_Log_JFA 
    -i /opt/jp1ajs2/embdb/_JFA -p 22230 -id _JFA -f 
    -mh logical_host -eh physical_host
#:

To use the backup enhancement function, specify the -b option for the ajsembdbbuild command.

(3) Environment setting parameter settings

No tasks are required if the common definition information and the settings on the executing host and on the standby host match and are in accordance with the procedures for the standby host in the following sections.

In Windows:
In UNIX:

(4) Setting up the scheduler database in an embedded database environment

No tasks are required for the standby host.

(5) Setting up multiple scheduler databases in one or more embedded database environments

The following describes how to set up multiple scheduler databases in one or more embedded databases.

(a) Setting up a different embedded database environment for each scheduler service

To set up a different embedded database environment for each scheduler service when multiple scheduler services are defined, prepare the areas listed below separately.

  • Embedded database practical directory

  • Embedded database work area

  • Unload log file creation directory

Prepare the unload log file creation directory if it is necessary.

When you set up an environment on the secondary node, it is not necessary to create the data area and system file area. Create these areas on a shared disk when the environment is created on the primary node.

When you set up an embedded database environment, specify a port number and embedded database setup identifier so that there are no duplication conflicts with other databases. That is, when executing the ajsembdbbuild command, you must specify a unique port number for each embedded database in the -p option. Similarly, when executing the ajsembdbinstl or ajsembdbbuild command, you must specify a unique embedded database setup identifier for each embedded database in the -id option.

An example of setup is shown below.

This example assumes that the environment described in 23.5.2(2) Setting up the embedded database environment and 23.5.2(3) Environment setting parameter settings is already set up.

■ For Windows

Environment for the embedded database:

The following are the details of the embedded database environment to be added:

  • Data area creation directory: q:\EmbDB\RDArea

  • System file area creation directory 1: r:\EmbDB\SYSArea1

  • System file area creation directory 2: s:\EmbDB\SYSArea2

  • Unload log file creation directory: t:\EmbDB\Unload_Log

  • Embedded database work area directory: u:\EmbDB\WorkArea

  • Embedded database installation directory: c:\Program Files#\HITACHI\JP1AJS2\embdb\_JFB

  • Scheduler service name: AJSROOT5

  • Embedded database port number: 22231

  • Embedded database setup identifier: _JFB

  • Physical host name of the primary node: physical_host

  • Logical host name: logical_host

#:

For 64-bit versions of Windows, replace Program Files with Program Files (x86).

Specification of the ajsembdbinstl command:
ajsembdbinstl -mh logical_host 
-s "c:\Program Files\HITACHI\JP1AJS2\tools\AJS3DB" 
-i "c:\Program Files\HITACHI\JP1AJS2\embdb\_JFB" -id _JFB
Specification of the ajsembdbbuild command:
ajsembdbbuild -l 
-d "q:\EmbDB\RDArea,r:\EmbDB\SYSArea1,s:\EmbDB\SYSArea2" 
-ld u:\EmbDB\WorkArea -br -bl t:\EmbDB\Unload_Log 
-i "c:\Program Files\HITACHI\JP1AJS2\embdb\_JFB" -p 22231 
-id _JFB -f -mh logical_host -eh physical_host
Procedure for setup in an embedded database environment:

For details about how to set up scheduler databases in an embedded database environment, see the specification examples in 23.5.2(4) Setting up the scheduler database in an embedded database environment.

■ For UNIX

Environment for the embedded database:

The following are the details of the embedded database environment to be added:

  • Data area creation directory: /share4/RDArea_JFB

  • System file area creation directory 1:/share5/SYSArea_JFB

  • System file area creation directory 2: /share6/SYSArea_JFB

  • Unload log file creation directory:/Unload_Log_JFB

  • Embedded database work area directory:/WorkArea_JFB

  • Embedded database practical directory: /opt/jp1ajs2/embdb/_JFB

  • Scheduler service name: AJSROOT5

  • Embedded database port number: 22231

  • Embedded database setup identifier: _JFB

  • Physical host name of the primary node: physical_host

  • Logical host name: logical_host

Specification of the ajsembdbinstl command:
ajsembdbinstl -mh logical_host -s /opt/jp1ajs2/tools/AJS3DB 
-i /opt/jp1ajs2/embdb/_JFB -id _JFB
Specification of the ajsembdbbuild command:
ajsembdbbuild -l 
-d "/share4/RDArea_JFB,/share5/SYSArea_JFB,
/share6/SYSArea_JFB" 
-ld /WorkArea_JFB -br -bl /Unload_Log_JFB 
-i /opt/jp1ajs2/embdb/_JFB -p 22231 -id _JFB 
-f -mh logical_host -eh physical_host
Procedure for setup in an embedded database environment:

For details about how to set up scheduler databases in an embedded database environment, see the specification examples in 23.5.2(4) Setting up the scheduler database in an embedded database environment.

For details about the ajsembdbinstl and ajsembdbbuild commands, see 2. Commands Used during Setup in the manual JP1/Automatic Job Management System 3 Command Reference.

(b) Setting up multiple scheduler databases in one embedded database environment

For details, see 23.5.2(4) Setting up the scheduler database in an embedded database environment.

(6) Setting up an embedded database again

To set up an embedded database again:

  1. Use the ajsembdbunset command to delete the data about the embedded database environment.

  2. If you need to change the embedded database practical directory, uninstall the embedded database, and then reinstall it.

  3. Use the ajsembdbbuild command to set up the embedded database.

  4. Set the common definition information of the primary node on the secondary node.

    When you have completed setup of the primary node, execute the jbsgetcnf command on the primary node to save the common definition information to a file.

    Copy the saved file to the secondary node, specify the name of the saved file in the jbssetcnf command, and execute the following commands:

    • Command to be executed on the primary node:

      jbsgetcnf -h logical-host-name > backup-file-name

    • Command to be executed on the secondary node:

      jbssetcnf backup-file-name

For details about the ajsembdbunset and ajsembdbbuild commands, see 2. Commands Used during Setup in the manual JP1/Automatic Job Management System 3 Command Reference. For details about the jbsgetcnf and jbssetcnf commands, see the JP1/Base User's Guide.

In Windows, make sure that JP1/AJS3 Database _JFn# has stopped before you start the JP1/AJS3 for the first time after the embedded database has been set up again. For details, see 8.2.6 Registering the JP1/AJS3 service in the cluster software.

#

_JFn is the embedded database setup identifier used by JP1/AJS3 services on a logical host.

(7) Changing the embedded database settings to the settings for a version earlier than 10-00

To change the embedded database management function to a version earlier than JP1/AJS3 - Manager 10-00:

  1. Perform an overwrite installation of the embedded database.

    Execute the ajsembdbinstl command with the -v9standard option specified.

    For details about the ajsembdbinstl command, see ajsembdbinstl in 2. Commands Used during Setup in the manual JP1/Automatic Job Management System 3 Command Reference.

  2. Change the settings in the system common definition file.

    Use an editor to open the following file, and then change the settings.

    System common definition file

    - In Windows:

    embedded-database-practical-directory\conf\pdsys

    - In UNIX:

    embedded-database-practical-directory/conf/pdsys

    Before the change:

    set pd_mode_conf = MANUAL2

    After the change:

    set pd_mode_conf = MANUAL1#

    #

    If you changed the system common definition file in JP1/AJS3 - Manager version 9 or earlier, use that value rather than MANUAL1.

(8) Uninstalling an embedded database

For details about uninstalling an embedded database, see 6.1.1(3) Uninstalling an unnecessary database environment.