6.4.3 Preventing a queueless job from ending abnormally with return value 128
If all of the following conditions are satisfied when a queueless job is executed, the job might end abnormally with return value 128:
-
There is an OS user who is not currently executing any jobs.
-
The OS user in condition 1 executes a job.
-
At the moment the job in condition 2 terminates, the OS user executes another job.
If a job ends abnormally when the above conditions are satisfied, you can prevent the abnormal termination and have the job end normally by setting the AJSQL_CREATEWINDOWSTATION environment setting parameter. The following describes how to set this environment setting parameter.
- Organization of this subsection
(1) Definition procedure
-
In Windows Control Panel, open the Services administrative tool, and stop the following service:
-
JP1/AJS3 Queueless Agent service
-
-
In a text editor such as Notepad, create a configuration file that defines the environment setting parameter described in (2) below.
The configuration file can be given any name.
-
Save the file and then execute the following command:
jbssetcnf configuration-file-name
The path of the jbssetcnf command is JP1/Base-installation-folder\bin\jbssetcnf. For details on this command, see the Job Management Partner 1/Base User's Guide.
-
Restart the service that you stopped in step 1.
The new settings are applied.
(2) Environment setting parameter
Definition key |
Environment setting parameter |
Explanation |
---|---|---|
[JP1_DEFAULT\JP1QLAGENT] |
"AJSQL_CREATEWINDOWSTATION"= |
Specifies whether to prevent a job from ending abnormally with return value 128. |
For details about the definition of this environment setting parameter, see 2.7.2(14) AJSQL_CREATEWINDOWSTATION in the Job Management Partner 1/Automatic Job Management System 3 Configuration Guide 2.
(3) Notes
-
If this setting is enabled, the first time that an OS user executes a job, the queueless agent service secures a desktop heap for job execution for that OS user. The queueless agent service then caches the heap in the user mapping cache. The desktop heap that has been secured is not released when the job ends. If the same user subsequently executes jobs, the applicable desktop heap in the user mapping cache is reused. Accordingly, if many OS users are executing jobs, it might not be possible to secure desktop heaps for all of them. If a user executes a job, but a desktop heap cannot be secured, the following message is output and the status of the job becomes Failed to start:
KAVS1829-E A system call (CreateDesktop) error occurred in the Queueless Agent service. : xxxxxxxx 8
If this message is output, execute the ajsqlalter command or restart the queueless agent service to clear the user mapping cache and reduce the number of OS users that are used to execute jobs. For details about the ajsqlalter command, see ajsqlalter in 3. Commands Used for Special Operation in the manual Job Management Partner 1/Automatic Job Management System 3 Command Reference 2.
If it is not possible to reduce the number of OS users used to execute jobs, reduce the size of the desktop heaps used by applications. For details about how to change the size of desktop heaps, see the documentation for the OS.
-
Enabling this setting will not prevent abnormal end of a job with return value 128 caused by insufficient desktop heap space.