iCan Blog Archive

SQL server mode jobs are the jobs named QSQSRVR that run in the QSYSWRK subsystems. One of the more common concerns that has been raised with QSQSRVR jobs is the difficulty to manage them, and in particular, the inability to configure the subsystem in which they run.

By default, the QSQSRVR jobs run in the QSYSWRK subsystem. IBM has made available PTFs on the 6.1 and 5.4 releases to allow you to control the subsystem in which these jobs run. This support is in the base operating system starting with release 7.1. You will need to create an environment variable to turn on the capability to run these jobs in other subsystems. The PTF solution is rather simple; the environment variable indicates that the QSQSRVR server mode jobs should run in the same subsystem as the requesting job.

It is highly recommended that you add prestart job entries to the subsystem where the QSQSRVR jobs will be run. Prestart jobs allow the job to be available when the request is received, as well as allowing the job to be reused and are important for best performance. If the prestart job entry does not exist, a batch immediate job will be used, which has more overhead.

See the PTF cover letters for the detailed instructions on creating the environment variable and setting up the prestart job entries. 

In the 7.1 release, this capability is now part of the JDBC connection properties and the CLI connection attributes. You specify the server mode subsystem where the jobs should run. By default, the jobs will run in QSYSWRK, but you can specify a specific subsystem name, or you can specify *SAME, which indicates the QSQSRVR jobs will run in the same subsystem as the job making the request.

Like described above for the PTF solutions on 6.1 and 5.4, on later releases you should also ensure that a prestart job entry exists for the QSQSRVR job in the desired subsystem description. If the prestart job entry does not exist, the QSQSRVR job will run as a batch immediate job.

IBM Support has the article QSQSRVR Subsystem Customization for more details.

This blog post was edited for currency on February 1, 2020.

This blog post was originally published on IBMSystemsMag.com and is reproduced here by permission of IBM Systems Media.