Hitachi

Job Management Partner 1 Version 10 Job Management Partner 1/Automatic Job Management System 3 Administration Guide


2.3.3 Recovering the JP1/AJS3 - Manager setup information

The following table lists the tasks required to recover the JP1/AJS3 - Manager setup information from the backup.

Table 2‒15: Tasks for recovering the JP1/AJS3 - Manager setup information

Task

Windows

UNIX

Recovering the physical host environment and logical host environment

Y

Y

Recovering the definition files

Y

Y

Clearing the information in the shared memory

N/A

Y

Creating a scheduler service database

Y

Y

Creating an execution environment for QUEUE jobs and submit jobs

(only if QUEUE jobs and submit jobs are used)

Y

Y

Recovering the execution agent information

Y

Y

Recovering the unit definition

Y

Y

Starting JP1/AJS3 (cold start)

Y

Y

Recovering the JP1/AJS3 Console setup information

(only if the JP1/AJS3 Console functionality is used)

Y

Y

Legend:

Y: Required

N/A: Not applicable

The following describes the tasks required to recover the JP1/AJS3 - Manager setup information from the backup.

Organization of this subsection

(1) Recovering the physical host environment and logical host environment

After setting up JP1/AJS3 - Manager, recover the physical host environment and logical host environment. For details about the settings required for recovery, see 3.1.2 Setting up JP1/AJS3 - Manager in the Job Management Partner 1/Automatic Job Management System 3 Configuration Guide 1 (in Windows) or 13.1.2 Setting up JP1/AJS3 - Manager in the Job Management Partner 1/Automatic Job Management System 3 Configuration Guide 1 (in UNIX).

(2) Recovering the definition files

Restore the definition files that were backed up to their original locations.

When migrating from JP1/AJS2 - Manager to JP1/AJS3 - Manager, carry out the procedure described in (10) Converting the startup process definition file after restoring the definition files.

Cautionary note

Before you recover the definition files, make sure that the following conditions exist:

  1. JP1/Base is installed, and the physical host environment has been set up.

  2. JP1/AJS3 is installed, and the physical host environment has been set up.

  3. JP1 in the logical host environment has been set up (for recovery of a logical host environment).

  4. JP1/Base and JP1/AJS3 are not running.

  5. The shared disk is mounted (to recover the settings file of a logical host).

(3) Clearing the information in the shared memory (only in UNIX)

Clear the information about the scheduler services saved in the shared memory when JP1/AJS3 was running. If information remains in the shared memory, the scheduler services restored by the recovery processing might be affected.

To clear the information in the shared memory:

  1. Execute the following command to make sure that all JP1/AJS3 services have stopped.

    • To check a physical host:

      # /opt/jp1ajs2/bin/jajs_spmd_status

    • To check a logical host:

      # /opt/jp1ajs2/bin/jajs_spmd_status -h logical-host-name

    • To check the JP1/AJS3 monitor functions:

      # ps -ef | grep ajsinetd

    Cautionary note

    Stop all the JP1/AJS3 services.

  2. Execute the following command to clear the information about the scheduler services saved in the shared memory.

    # /opt/jp1ajs2/bin/ajsshmdel

(4) Creating the scheduler service database

If the scheduler service database is corrupted, you need to re-create it as described below.

Note that you need to stop all the JP1/AJS3 services when creating a scheduler service database. In UNIX, use the procedure in (3) Clearing the information in the shared memory (only in UNIX).

To create the scheduler service database :

  1. Execute the ajsembdbunset command to delete the embedded database environment.

    ajsembdbunset -e -id embedded-database-setup-identifier
  2. Execute the ajsembdbbuild command to create the embedded database environment.

    For details about how to use the ajsembdbbuild command to create an embedded database environment, see C.2(3) Setting up the embedded database environment in the Job Management Partner 1/Automatic Job Management System 3 Configuration Guide 1.

    For details about how to create an embedded database environment on the primary node in a logical host environment, see D.2(3) Setting up the embedded database environment in the Job Management Partner 1/Automatic Job Management System 3 Configuration Guide 1. For details about how to create an embedded database environment on the secondary node, see D.3(3) Setting up the embedded database environment in the Job Management Partner 1/Automatic Job Management System 3 Configuration Guide 1.

  3. Execute the ajsembdbsetup command to set up the JP1/AJS3 environment in the embedded database environment.

    For details about how to use the ajsembdbsetup command to set up the JP1/AJS3 environment, see C.2(5) Setting up the scheduler database in an embedded database environment in the Job Management Partner 1/Automatic Job Management System 3 Configuration Guide 1.

    For details about how to set up the JP1/AJS3 environment on the primary node in a logical host environment, see D.2(5) Setting up the scheduler database in an embedded database environment in the Job Management Partner 1/Automatic Job Management System 3 Configuration Guide 1. For details about how to set up the JP1/AJS3 environment on the secondary node, see D.3(5) Setting up the scheduler database in an embedded database environment in the Job Management Partner 1/Automatic Job Management System 3 Configuration Guide 1.

(5) Creating an execution environment for QUEUE jobs and submit jobs

Use the recovered configuration definition file (jpqsetup.conf) for the execution environment for QUEUE jobs and submit jobs to create the execution environment for QUEUE jobs and submit jobs.

Before creating the execution environment for QUEUE jobs and submit jobs, make sure that the JP1/AJS3 service on the target logical host is not running.

To create an execution environment:

  1. Execute the following command to delete the files in the folder containing the queue information database.

    • For Windows

      del database-directory-for-QUEUE-and-submit-jobs\*#

    • For UNIX

      rm database-directory-for-QUEUE-and-submit-jobs/*#

    #

    The database directory of the execution environment for QUEUE jobs and submit jobs is the folder specified in the environment setting parameter DatabasePath in [{JP1_DEFAULT|logical-host-name}\JP1NBQMANAGER\Database].

    For details about the environment setting parameter DatabasePath, see 2.3.2(3) DatabasePath in the Job Management Partner 1/Automatic Job Management System 3 Configuration Guide 2.

  2. Execute the following command to create an execution environment for QUEUE jobs and submit jobs.

    jpqimport -dt isam -ci jpqsetup.conf  [-mh logical-host-name]
    Cautionary note

    For the configuration definition file (jpqsetup.conf) for the execution environment of QUEUE jobs and submit jobs, use the recovered file.

    To recover a logical host definition, specify the logical host name in the -mh option.

(6) Starting JP1/AJS3

Restart the JP1/AJS3 services with a cold start.

(7) Recovering the execution agent information

The following describes the tasks required to recover the execution agent information.

Execute the following command to recover the execution agent information from the backup of the execution agent definition file.

ajsagtadd [-h logical-host-name] -f execution-agent-definition-file [-i]
Cautionary note

If an error occurs during the processing to add information, the processing stops immediately. However, you can specify the -i option to continue the processing even if an error has occurred.

(8) Recovering the unit definition

The following describes the tasks required to recover the setup information of jobnets and calendars. Recover the setup information for each scheduler service.

Cautionary note

For this recovery procedure only, the unit for recovery is by scheduler service rather than by logical host. Accordingly, recover the setup information for each scheduler service separately.

(a) Recovering the definition information for units other than the root job group

Execute the following command to recover the definition information for the units in the scheduler service. The definition information includes the base time, comments, and all other definitions for each unit, but does not include information about the root job group (/), such as the base time, base day, and base month. To recover the root job group information, use the procedures in (b) Recovering the information about the root job group and (c) Recovering the calendar information for the root job group below.

ajsdefine -F scheduler-service-name unitbackup.txt

If the information has been split by job group or jobnet during backup, execute the following command for each backup unit to be recovered.

ajsdefine -F scheduler-service-name -d definition-destination-unit-name unit-name_backup.txt

(b) Recovering the information about the root job group

Set the following information about the root job group that you have recorded.

  • Comments

  • Owners

  • JP1 resource groups

  • Base time

  • Base day

  • Base month

(c) Recovering the calendar information for the root job group

Execute the following command to recover the calendar information (open days and close days) for the root job group.

ajscalendar -F scheduler-service-name -df rootcal.txt /
Cautionary note

This command recovers the calendar of the scheduler service itself.

If no calendar information has been output to rootcal.txt, recovery is not needed. For details, see the backup procedure.

(9) Recovering and setting up the JP1/AJS3 Console setup information

When the JP1/AJS3 Console functionality is used, perform the operations below.

Cautionary note

Before you start recovery and setup, make sure that the following conditions exist:

  • JP1/AJS3 Console Manager, JP1/AJS3 Console Agent, and other JP1 series programs that require JP1/Base are not running.

  • The shared disk is mounted (to recover the setup information for a logical host).

(a) Recovering the JP1/AJS3 Console setup information

Restore the JP1/AJS3 Console backup files to their original locations.

(b) Setting up JP1/AJS3 Console

Set up JP1/AJS3 Console Manager and JP1/AJS3 Console Agent.

(10) Converting the startup process definition file

Execute the jajs_convert_to_spmd command to convert the startup process definition file used for system management. This procedure is only required when migrating from JP1/AJS2 - Manager to JP1/AJS3 - Manager.

To convert the startup process definition file:

(a) In Windows

  • For a physical host in a standard configuration

    cd c:\Program Files\HITACHI\JP1AJS2\tools
    jajs_convert_to_spmd -c standard
  • For a logical host in a standard configuration

    cd c:\Program Files\HITACHI\JP1AJS2\tools
    jajs_convert_to_spmd -h LHOST -c standard
  • For a physical host in a compatible ISAM configuration

    cd c:\Program Files\HITACHI\JP1AJS2\tools
    jajs_convert_to_spmd -c ISAM
  • For a logical host in a compatible ISAM configuration

    cd c:\Program Files\HITACHI\JP1AJS2\tools
    jajs_convert_to_spmd -h LHOST -c ISAM

The jajs_convert_to_spmd command is a tool used for migration, which can be found in the folder JP1/AJS3 - Manager-installation-folder\tools.

(b) In UNIX

  • For a physical host in a standard configuration

    /opt/jp1ajs2/tools/jajs_convert_to_spmd -c standard
  • For a logical host in a standard configuration

    /opt/jp1ajs2/tools/jajs_convert_to_spmd -h LHOST -c standard
  • For a physical host in a compatible ISAM configuration

    /opt/jp1ajs2/tools/jajs_convert_to_spmd -c ISAM
  • For a logical host in a compatible ISAM configuration

    /opt/jp1ajs2/tools/jajs_convert_to_spmd -h LHOST -c ISAM

(c) Cautionary note

If you restricted the use of JP1/AJS2 - Manager to the registration and manipulation of submit jobs, after using the jajs_convert_to_spmd command to convert the startup process definition file, apply the same restriction to the recovered environment by following the steps in 7.1.2 Setup for using QUEUE jobs and submit jobs in the Job Management Partner 1/Automatic Job Management System 3 System Design (Configuration) Guide.