IBM SC34-7012-01 manual Flushing journal buffers, PERFORM IMMEDIATE not recommended

Models: SC34-7012-01

1 268
Download 268 pages 41.5 Kb
Page 40
Image 40
Flushing journal buffers

Flushing journal buffers

During a successful normal shutdown, CICS calls the log manager domain to flush all journal buffers, ensuring that all journal records are written to their corresponding MVS system logger log streams.

During an immediate shutdown, the call to the log manager domain is bypassed and journal records are not flushed. This also applies to an immediate shutdown that is initiated by the shutdown-assist transaction because a normal shutdown has stalled. Therefore, any user journal records in a log manager buffer at the time of an immediate shutdown are lost. This does not affect CICS system data integrity. The system log and forward recovery logs are always synchronized with regard to I/O and unit of work activity. If user journal data is important, you should take appropriate steps to ensure that journal buffers are flushed at shutdown.

These situations and possible solutions are summarized as follows:

vIn a controlled shutdown that completes normally, CICS ensures that user journals are flushed.

vIn a controlled shutdown that is forced into an immediate shutdown by a shutdown-assist transaction, CICS does not flush buffers. To avoid the potential loss of journal records in this case, you can provide a PLTSD program that issues a SET JOURNAL FLUSH command to ensure that log manager buffers are written to the corresponding log streams. PLTSD programs are invoked before an immediate shutdown is initiated by the shutdown-assist transaction.

vIn an uncontrolled shutdown explicitly requested with the SHUT IMMEDIATE command, CICS does not flush buffers. To avoid the potential loss of journal records in this case, you can issue an EXEC CICS WAIT JOURNALNAME command at appropriate points in the application program, or immediately before returning control to CICS. (Alternatively, you could specify the WAIT option on the WRITE JOURNALNAME command.) See the description of the command in the CICS Application Programming Reference for information about the journaling WAIT option.

Immediate shutdown processing (PERFORM SHUTDOWN IMMEDIATE)

As a general rule when terminating CICS, you are recommended to use a normal shutdown with a shutdown assist transaction, specifying either your own or the CICS-supplied default, CESD.

PERFORM IMMEDIATE not recommended

You should resort to using an immediate shutdown only if you have a special reason for doing so. For instance, you might need to stop and restart CICS during a particularly busy period, when the slightly faster immediate shutdown may be of benefit. Also, you can use VTAM persistent sessions support with an immediate shutdown.

You initiate an immediate shutdown by a CEMT, or EXEC CICS, PERFORM SHUTDOWN IMMEDIATE command. Immediate shutdown is different from a normal shutdown in a number of important ways:

1.If the shutdown assist transaction is not run (that is, the SDTRAN system initialization parameter specifies NO, or the PERFORM SHUTDOWN command specifies NOSDTRAN), user tasks are not guaranteed to complete. This can lead to an unacceptable number of units of work being shunted, with locks being retained.

28CICS TS for z/OS 4.1: Recovery and Restart Guide

Page 40
Image 40
IBM SC34-7012-01 manual Flushing journal buffers, Immediate shutdown processing PERFORM SHUTDOWN IMMEDIATE