Force a stall on a database resource with DML/O
search cancel

Force a stall on a database resource with DML/O

book

Article ID: 9852

calendar_today

Updated On:

Products

IDMS IDMS - Database

Issue/Introduction

This document describes a method to force a database related stall using DML/O.

If there is a need to test some functionality regarding STALLs (DC001003), for example an APAR or a new application giving problems, it might be useful to be able to force a STALL.

Environment

Release: All supported releases.

Resolution

First, set the STALL interval for the DMLO task to something specific. For example this will set it to 30 seconds:

DCMT VARY TASK DMLO STALL 30

(Note, in the SYSTEM GENERATION definition, this parameter is called the INACTIVE INTERVAL.)

Now, using DML/O, READY the database area in SHARED UPDATE usage-mode and then OBTAIN and MODIFY one particular record occurrence. Leave that session open.

Then, in a second DML/O session, do the same, but this time only OBTAIN the same record occurrence.

The problem in forcing a stall on a database resource is that at this point, it is likely that there will be a stall on the PTERM of the first session before the database transaction stalls.

To avoid this, enter any command in the first DML/O session at least once every 30 seconds while the second session is being created. The command can be the simple OBTAIN on the same record – it doesn’t matter. As long as the session isn't FINISHed, the exclusive lock which is what is required to get the stall will still be held.

Eventually, the second session will get the stall. Message such as these will appear on the dc-log (OLP):

IDMS DC001007 V1 T232 TASK:DMLO PROG:USDTPIF2 WAITING FOR LTXNLOCK 00000008 0124FF01
IDMS DC001008 V1 T232 TXNID:15899 PROG:USDMAIN0 SUBSCHEMA:EMPSS01 MODE:S
IDMS DC001009 V1 T232 TSKID:229 TASK:DMLO PROG:USDTPIF2 HOLDS LTXNLOCK 00000008 0124FF01
IDMS DC001010 V1 T232 TXNID:15894 PROG:USDMAIN0 SUBSCHEMA:EMPSS01 MODE:X
IDMS DC001003 V1 T232 TASK:DMLO PROG:USDTPIF2 STALLED WAITING FOR LTXNLOCK 00000008 0124FF01
IDMS DC027007 V1 T232 TASK:DMLO PROG:USDTPIF2 ABENDED WITH CODE D002

The interval can be anything, but a balance must be struck between it being long enough to allow the DML/O commands to be issued and short enough so that the wait is not so long. 30 seconds should be fine.

Additional Information