8.2.7 Setting up the queueless job execution environment
When queueless jobs are used and the nodes are switched, the logical hosts that are currently attached to the currently active node must be detached, and then re-attached to the node that will become active.
To ensure that the detachment and re-attachment of the logical hosts is performed automatically when the nodes are switched, use the applicable procedure described below.
- Organization of this subsection
-
(1) Procedure used when JP1/AJS3 - Manager or JP1/AJS3 - Agent is installed and set up as a new installation
If you install and set up JP1/AJS3 - Manager or JP1/AJS3 - Agent as a new installation, perform the following procedure on both the primary and secondary nodes.
To ensure that logical hosts are automatically detached and re-attached:
-
Install JP1/AJS3 - Manager or JP1/AJS3 - Agent as a new installation.
For details about the installation procedure, see 2.2.3 Installing a JP1/AJS3 series program.
-
Set up the physical host.
For details about the setup procedure, see 3. Setup.
-
Set up the logical hosts.
For details about the setup procedure, see 8.2.2 Procedure for setting up a cluster system environment (in Windows version of JP1/AJS3 - Manager) and 8.2.3 Procedure for setting up a cluster system environment (in Windows version of JP1/AJS3 - Agent).
-
Edit the jp1ajs_hstd.conf file.
Edit the jp1ajs_hstd.conf file that was set up in step 3.
-
If you have installed JP1/AJS3 - Manager and have updated the jp1ajs_hstd.conf file during, for example, setting of a standard configuration without ISAM or during configuration of scheduler status monitoring
Back up the jp1ajs_hstd.conf file, and then add the following line to the beginning of the jp1ajs_hstd.conf file.
qlcltd|ajsqlcltd.exe|||1800|
-
If you have installed JP1/AJS3 - Manager but have not updated the jp1ajs_hstd.conf file
After creating a backup of the jp1ajs_hstd.conf file, delete the jp1ajs_hstd.conf file. Next, copy the jp1ajs_hstd_ql.conf.model file, and then rename the copy to jp1ajs_hstd.conf.
-
If you have installed JP1/AJS3 - Agent
After creating a backup of the jp1ajs_spmd.conf file, delete the jp1ajs_spmd.conf file. Next, copy the jp1ajs_spmd_ql.conf.model file, and then rename the copy to jp1ajs_spmd.conf. You do not need to edit the jp1ajs_hstd.conf file.
The jp1ajs_hstd.conf and jp1ajs_hstd_ql.conf.model files are located in the shared-folder-name\jp1ajs2\conf folder.
-
-
Start the queueless agent service and the queueless file transfer service.
Start the queueless agent service. If you have installed JP1/AJS3 - Manager, also start the queueless file transfer service.
(2) Procedure used when JP1/AJS3 - Manager or JP1/AJS3 - Agent is installed and set up as an upgrade installation
If you install and set up JP1/AJS3 - Manager or JP1/AJS3 - Agent as an upgrade installation of version 7 of JP1/AJS2 - Manager or JP1/AJS2 - Agent, perform the following procedure on both the primary and secondary nodes.
To ensure that the logical hosts are automatically detached and re-attached:
-
Install JP1/AJS3 - Manager or JP1/AJS3 - Agent as an upgrade installation.
For details about the installation procedure, see 2.2.3 Installing a JP1/AJS3 series program.
If JP1/AJS3 - Manager or JP1/AJS3 - Agent has already been installed as an upgrade installation, skip this step.
-
Set up the queueless job execution environment on the physical host.
If the queueless job execution environment has not been set up on the physical host, use the ajsqlsetup command to set it up. For details about the ajsqlsetup command, see ajsqlsetup in 4. Commands Used for Special Operation in the manual JP1/Automatic Job Management System 3 Command Reference.
-
Set up the logical hosts.
If you have not set up the logical hosts yet, set them up.
For details about the setup procedure, see 8.2.2 Procedure for setting up a cluster system environment (in Windows version of JP1/AJS3 - Manager) and 8.2.3 Procedure for setting up a cluster system environment (in Windows version of JP1/AJS3 - Agent).
If the queueless job execution environment has not been set up when you are ready to set up the logical hosts, use the ajsqlsetup command to set up the queueless job execution environment. For details about the ajsqlsetup command, see ajsqlsetup in 4. Commands Used for Special Operation in the manual JP1/Automatic Job Management System 3 Command Reference.
-
Edit the jp1ajs_hstd.conf file.
Edit the jp1ajs_hstd.conf file of the logical hosts for which you want to enable automatic attachment and detachment.
-
If you have installed JP1/AJS3 - Manager as an upgrade installation
Check whether the jp1ajs_hstd.conf file contains the line shown below. If this line is not found, back up the jp1ajs_hstd.conf file, and then add the following line to the beginning of the jp1ajs_hstd.conf file:
qlcltd|ajsqlcltd.exe|||1800|
-
If you have installed JP1/AJS3 - Agent as an upgrade installation
After creating a backup of the jp1ajs_spmd.conf file, delete the jp1ajs_spmd.conf file. Next, copy the jp1ajs_spmd_ql.conf.model file, and then rename the copy to jp1ajs_spmd.conf. You do not need to edit the jp1ajs_hstd.conf file.
The jp1ajs_hstd.conf and jp1ajs_hstd_ql.conf.model files are located in the shared-folder-name\jp1ajs2\conf folder.
-
-
Start the queueless agent service and the queueless file transfer service.
Start the queueless agent service. If you have installed JP1/AJS3 - Manager, also start the queueless file transfer service.
After the above settings have been specified, the queueless cluster process is started when the JP1/AJS3 service is started on the logical hosts. The queueless cluster process automatically attaches the logical hosts. When the JP1/AJS3 service stops on the logical hosts, the queueless cluster process also stops and the queueless cluster process automatically detaches the logical hosts.
(3) Notes on automatic attachment and detachment of logical hosts performed when queueless jobs are used
-
This function must be set on each logical host. A queueless cluster process is generated for each logical host.
You do not need to set this function on logical hosts that do not use queueless jobs.
-
You can also set this function on the logical hosts that are not in a cluster system.
-
If you do not use this function during cluster system operation, manually execute the ajsqlattach command and the ajsqldetach command when nodes are switched to attach and detach logical hosts.
-
Before you use this function, you must start the queueless agent service on both the primary and secondary nodes. You do not need to start and stop the queueless agent service when nodes are switched.
-
This function cannot be used on physical hosts.
-
By default, the queueless cluster process does not terminate abnormally even if automatic attachment fails and the startup processing of the JP1/AJS3 service on logical hosts continues. If you want to terminate the queueless cluster process abnormally to cancel the startup processing of the JP1/AJS3 service, set error for the AJSQL_CLUSTERREQ environment setting parameter. For details about AJSQL_CLUSTERREQ, see 20.10 Setting up the queueless job execution environment.
-
If automatic detachment fails, the queueless cluster process terminates abnormally. The processing to stop the JP1/AJS3 service on logical hosts also terminates abnormally.
-
If this function is used, the status of the queueless cluster process is also output in the execution result of the jajs_spmd_status command. If this function is not used, the execution result of the jajs_spmd_status command does not include this status.
Output example when the function is not used:
c:\>jajs_spmd_status -h LHOST1 KNAD3690-I Processing to report the status of JP1/AJS3 has started. Running processes are as follows: Process name Scheduler service name Process ID jajs_dbmd 301 ajsdbmgrd 310 ... jpomanager AJSROOT1 557 ajsmasterd AJSROOT1 565 KNAD3691-I All the processes have started.
Output example when the function is used:
c:\>jajs_spmd_status -h LHOST1 KNAD3690-I Processing to report the status of JP1/AJS3 has started. Process name Scheduler service name Process ID jajs_dbmd 301 ajsdbmgrd 310 ... qlcltd 320 ... jpomanager AJSROOT1 557 ajsmasterd AJSROOT1 565 KNAD3691-I All the processes have started.
(4) Other notes
-
This note applies when a logical host is attached with the AJSQL_ATTACH environment setting parameter set to yes. If the nodes are switched in this state, cluster software or another means must be used to stop the queueless agent service on the active node and to start the queueless agent service on the standby node.
In this case, the status of the queueless jobs running on the physical host or on other logical hosts attached to the queueless agent service on the active node might become Failed to start, Ended abnormally, or Unknown end status. If queueless jobs must be executed on multiple hosts, use this function without enabling AJSQL_ATTACH.
For details about the AJSQL_ATTACH environment setting parameter, see 20.10 Setting up the queueless job execution environment.
-
Do not allow operation with only logical hosts when physical hosts have been detached from the queueless agent service.
If you do so, an error message output when startup of a queueless job fails and information output to the standard error output during job execution might not be reported to the manager host.