DataStore routing during IMS shutdown
Suspending message routing
Use one of the following methods to suspend message routing before you issue the STOP DATASTORE and /CHE commands:
- Issue the SET ROUTER INACTIVE command. For more information, see SET-commands-to-reset-the-journal-and-trace-fields-temporarily.
- Set the router load weight to zero.
You can perform either method via the Energizer ISPF interface. You can issue the SET ROUTER INACTIVE command also via the Batch utility.
Energizer then routes inbound messages to the next available datastore and returns the corresponding responses to the IMS Connect clients. The messages sent to the datastore with suspended routing are processed by the next available datastore. New messages are not routed to the datastores with suspended routing.
OTMA processes messages sent to it before you issued the SET ROUTER INACTIVE command that have not yet returned a response (inflight messages) and the corresponding responses are returned to the IMS Connect clients.
Resuming message routing
After you restart (cold start or emergency restart) the IMS system and all datastores become available, perform one of the following step, depending on how you suspended message routing:
- Issue the SET ROUTER ACTIVE command. For more information, see SET-commands-to-reset-the-journal-and-trace-fields-temporarily.
- Reset the router load weight to an appropriate value.
To suspend message routing by using the ISPF interface
- Navigate to the Energizer Commands - DataStores panel.
For information about how to navigate to the panel, see Issuing-Energizer-commands. - Identify the datastores associated with the IMS system that you plan to shut down.
- Perform one of the following actions and press Enter:
- Set the identified datastore to INACTIVE (option 6 on the panel).
- Set the router load weight to zero (option 7 on the panel).
- Verify that message routing is suspended by checking the -Display Stats Summary(DS) Id(*) field (option 3 on the panel).
- Issue the /CHE command to shut down the IMS system.
- After the maintenance or similar task is complete, restart the IMS system.
- To resume message routing, perform one of the following actions and press Enter:
- Set the inactive datastore to ACTIVE (option 5 on the panel).
- Set the router load weight to an appropriate value (option 7 on the panel).
To suspend message routing by using the Batch utility
Use the IPRTCPIC member located in the BMCSAMP library to issue IMS and Energizer commands in batch mode. The sample JCL member IPR#REXX to execute the IPRTCPIC member is available in the BMCCNTL library.
- For the datastores associated with the IMS system that you plan to shut down, follow these steps:
Create a set of batch jobs that issue the SET ROUTE command to make a datastore INACTIVE. Use the following JCL in the IMS shutdown procedure:
//DSINACT EXEC PGM=IKJEFT01,DYNAMNBR=100
//SYSPROC DD DISP=SHR,DSN=<yourCLISTLibrary> BMCSAMP
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
%IPRTCPIC HOST:PORT# MSGID(-IPRCMD-) -
-SET ROUTER TYPE(DS) ID(<datastoreName>) STATE(INACTIVE) FORMATCreate a set of batch jobs that issue the SET ROUTE command to make a datastore ACTIVE. Use the following JCL in the IMS startup procedure:
//DSACT EXEC PGM=IKJEFT01,DYNAMNBR=100
//SYSPROC DD DISP=SHR,DSN=<yourCLISTLibrary> BMCSAMP
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
%IPRTCPIC HOST:PORT# MSGID(-IPRCMD-) -
-SET ROUTER TYPE(DS) ID(<datastoreName>) STATE(ACTIVE) FORMATCreate a set of batch jobs that issue the SET ROUTE command to set the router load weight to a value from 0 through 100. Use the following JCL in the IMS startup and shutdown procedures:
//DSLOAD0 EXEC PGM=IKJEFT01,DYNAMNBR=100
//SYSPROC DD DISP=SHR,DSN=<yourCLISTLibrary> BMCSAMP
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
%IPRTCPIC HOST:PORT# MSGID(-IPRCMD-) -
-SET ROUTER TYPE(DS) ID(<datastoreName>) LOAD(<nn>) FORMAT
- Run the jobs that suspend message routing.
- Issue the /CHE command to shut down the IMS system.
- After the maintenance or similar task is completed, restart the IMS system.
- Run the jobs that resume message routing.
Routing status and statistics summary
You can see the routing status and related statistics from the Energizer ISPF interface or via running a job.
On the Energizer Commands - DataStores panel, type 1 and press Enter to display the routing status. A sample output is shown in the following figure:
BMCIPA1010I OUTPUT FROM ORIGIN SYSTEM SD5DLCON@IMSA
BMCIPA1011I ROUTER CONFIGURATION: SD5DR15 FROM: 09/29/20-12:05
BMCIPA1011I AFFINITY MANAGEMENT IS: ACTIVE
BMCIPA1011I LOAD BALANCING IS: ACTIVE STATISTICAL
BMCIPA1011I DISPLAY STATE CHANGE MESSAGES: NO
BMCIPA1011I OVERRIDE IRM TIMER: 0.01 SECS.
BMCIPA1011I WARN STATE WEIGHT MULTIPLIER: 50%
BMCIPA1011I DATASTORE STATE CHANGE TIMER: 00:01:00 (HH:MM:SS)
BMCIPA1011I ROUTING CYCLE STARTED: 23:41:11 CYCLE TIME: 00:01:00
BMCIPA1011I DATASTORE WEIGHT %GOAL #MSGS %MSGS STATUS
BMCIPA1011I SD4A 0 0 0 0 ROUTING INACTIVE
BMCIPA1011I SD5D 33 50 0 0 AVAIL
BMCIPA1011I TEST 33 50 0 0 AVAIL
BMCIPA1099I COMMAND PROCESSING COMPLETE
Complete status Message - Flags: IPRCMD RC=0
For the datastore SD4A, the router load weight is 0 and the routing status is inactive. For the datastores SD5D and TEST, the routing status is active.
Use the following JCL to generate the sample output:
//SYSPROC DD DISP=SHR,DSN=<yourCLISTLibrary> BMCSAMP
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
%IPRTCPIC HOST:PORT# MSGID(-IPRCMD-) -
-DISPLAY ROUTER TYPE(DS) ID(*) FORMAT
On the Energizer Commands - DataStores panel, type 3 and press Enter to display the statistics summary. A sample output is shown in the following figure:
BMCIPA1010I OUTPUT FROM ORIGIN SYSTEM SD5DLCON@IMSA
BMCIPA1011I STATISTICS LAST RESET ON: 09/29/20 AT: 10:14:13 (OR LATER IF INDICATED BY *)
BMCIPA1011I --RATE (MSGS/SECOND)--- INPUT --INPUT MESSAGE SIZE --
BMCIPA1011I DATASTOR CURRENT RECENT PEAK MESSAGES AVERAGE MINIMUM MAXIMUM ERRORS
BMCIPA1011I -------- ------- ------- ------- ------- ------- ------- ------- ------
BMCIPA1011I SD5D * 0.00 0.00 1.20 287 105 105 105 0
BMCIPA1011I TEST * 0.00 0.00 1.40 290 105 105 105 0
BMCIPA1011I SD4A * 0.00 0.00 0.60 23 105 105 105 0
BMCIPA1011I SD5A * 0.00 0.00 0.00 0 0 0 0 0
BMCIPA1099I COMMAND PROCESSING COMPLETE
Complete status Message - Flags: IPRCMD RC=0
The value 0 in the CURRENT column for each datastore indicates that there are no incoming messages.
Use the following JCL to generate the sample output:
//SYSPROC DD DISP=SHR,DSN=<yourCLISTLibrary> BMCSAMP
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
%IPRTCPIC HOST:PORT# MSGID(-IPRCMD-) -
-DISPLAY STATS SUMMARY(DS) ID(*) FORMAT