IBM Support

Separating Batch Work from *BASE

Troubleshooting


Problem

This document describes how to separate the QBATCH subsystem from the *BASE pool into its own separate shared pool to improve performance of jobs running in the new shared pool.

Resolving The Problem

All IBM OS/400 or IBM i5/OS systems are shipped with predefined working environments. However, the way the system is shipped may not be suitable for all customer environments. The most fundamental and important parts of the working environment are the subsystem and the pool.

Subsystem

A subsystem is a single, predefined operating environment through which the system coordinates the work flow and resource use. A system has multiple subsystems, and each subsystem can run unique and/or different operations. Subsystems are defined using an object called a subsystem description (SBSD).

Pool

A pool is a division of main storage. On a system running OS/400 or i5/OS, all main storage can be divided into logical allocations called storage pools. The pool types include shared pools and private pools.

Shared Pool

A shared pool is a pool in which multiple subsystems can run jobs. The advantage of shared pools is the flexibility of sharing memory between pools if it is not being used. System value QPFRADJ adjusts memory to maximize resources on a dynamic system. Shared pools can also use Expert Cache by setting the paging option on the WRKSYSSTS or WRKSHRPOOL to *CALC.

Private Pool

A private pool is a pool in which only one subsystem can operate. The pool is always available for the subsystem and is not shared with other pools. The private pool is not able to use memory caching through the paging option.

You can control how much work can be done in a subsystem by controlling the number of jobs and the size of the pool. The greater the size of the pool, the more work can be done as long as the CPU can support it.

Taking batch work out of *BASE and separating it into a shared pool means that the different types of work, system and batch, each function more efficiently.

Assigning batch work its own pool is a matter of redefining the subsystem description and its associated routing entries. This example is assigning batch work to a shared pool.

QBATCH is the default batch subsystem. To assign a pool for batch work, do the following:

1.On the operating system command line, type WRKSBS. Type 5 next to QBATCH, and press the Enter key. Note the library name at the top of the screen. Select Option 2, Pool Definitions. Pool ID 1 should be *BASE. If there are other pool IDs, batch may already be separated (check routing entries to verify). If the entry contains a number, a private pool is defined. Press the Enter key.
2.Select Option 7, Routing Entries. Note each sequence number. Type 5 next to each routing entry. Press the Enter key to view each one and note the pool identifier. If there was a second pool in Step 1 above, the pool ID should be that of the second pool. If it is, batch is already separated. If not, continue.
3.On the operating system command line, type WRKSHRPOOL. The Pool ID column contains a number if the pool is already being used. Allocate memory to the first shared pool that does not have a Pool ID. Set the defined size(a minimum of .25), set the maximum active, and set the paging option to *CALC. Refer to the Work Management Guide for the suggested number of batch jobs the system can handle, and use 1000 to 5000 k for each job, depending on system size and available memory. The memory comes from pool 2 when the subsystem activates the pool and a Pool ID is assigned. The Pool ID refers to the WRKSYSSTS pool ID. For this example, SHRPOOL1 is used.
4.For releases prior to R310, you must end the subsystem to make the following changes. Check if there are jobs running before ending the subsystem using ENDSBS QBATCH *IMMED.

Type CHGSBSD and press F4 to prompt. Type the subsystem name and library (for example, QBATCH, QSYS). Assuming *BASE was assigned as pool 1 in Step 1 above, assign storage pool identifier 2 to storage size *SHRPOOL1, and leave the activity level blank. Press the Enter key. *BASE is needed as pool ID 1 for the subsystem monitor which manages jobs within the subsystem.

Change Subsystem Description (CHGSBSD)

Type choices, press Enter.

Subsystem description . QBATCH Name
Library . . . . . . . QSYS Name, *LIBL, *CURLIB
Storage pools:
Pool identifier . . . 2__ 1-10, *SAME
Storage size . . . . . *SHRPOOL1 Number, *BASE, *NOSTG.
Activity level . . . . _____ Number
5.Type CHGRTGE, and press F4 to prompt. Type the subsystem name, library name, routing entry sequence number, and storage pool identifier. Press the Enter key. Use F9 to recall the command for subsequent routing entries. Recall and change the sequence number until all routing entries are changed.

                              Change Routing Entry (CHGRTGE)

    Type choices, press Enter.                  
   Subsystem description  . . . .
QBATCH Name
     Library  . . . . . . . . . .  
QSYS Name, *LIBL, *CURLIB
   Routing entry sequence number  
30    1-9999
   Comparison data:                        
     Compare value  . . . . . . .
*SAME 
                                       

      Starting position  . . .           1-80, *SAME
   Program to call  . . . . . . .
*SAME Name, *SAME, *RTGDTA
     Library  . . . . . . . .
          Name, *LIBL, *CURLIB
   Class  . . . . . . . . . . . .
*SAME Name, *SAME, *SBSD  
     Library  . . . . . . . .
           Name, *LIBL, *CURLIB
   Maximum active routing steps  
*SAME 0-1000, *SAME, *NOMAX
    Storage pool identifier . .     2    1-10, *SAME

Press F9 to change the remaining routing entries as follows:

CHGRTGE SBSD(QSYS/QBATCH) SEQNBR(60) POOLID(2)
6.Verify the changes. Type WRKSBSD QBATCH, and select Option 5. Display. Then select Option 2, Pool Definitions and Option 7, Routing Entries. Pools should now be *BASE and *SHRPOOL1. Routing entries should all show pool identifier 2.
7.If QBATCH was ended, start it again using STRSBS QBATCH. The WRKSYSSTS command should now show an additional pool and the WRKSHRPOOL command should show a pool ID for *SHRPOOL1.
Work with Shared Pools (WRKSHRPOOL)

Main storage size (K) . : 393216

Type changes (if allowed), press Enter.

Defined Max Allocated Pool -Paging Option--
Pool Size (K) Active Size (K) ID Defined Current
*MACHINE 80216 +++ 80216 1 *FIXED *FIXED
*BASE 75000 131 75000 2 *CALC *CALC
*INTERACT 175000 100 175000 3 *CALC *CALC
*SPOOL 8000 2 8000 4 *CALC *CALC
-> *SHRPOOL1 55000 8 55000 5 *CALC *CALC
*SHRPOOL2 0 0 *FIXED
*SHRPOOL3 0 0 *FIXED
*SHRPOOL4 0 0 *FIXED
*SHRPOOL5 0 0 *FIXED
*SHRPOOL6 0 0 *FIXED
*SHRPOOL7 0 0 *FIXED
*SHRPOOL8 0 0 *FIXED
*SHRPOOL9 0 0 *FIXED
*SHRPOOL10 0 0 *FIXED

[{"Type":"MASTER","Line of Business":{"code":"LOB57","label":"Power"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SWG60","label":"IBM i"},"Platform":[{"code":"PF012","label":"IBM i"}],"Version":"7.1.0"}]

Historical Number

349033974

Document Information

Modified date:
18 December 2019

UID

nas8N1015956