These procedures are all run on a R&D LPAR.
Purpose is to delete and refresh test environments.
They are all run from AJS, which is the reason for the STRWCH.
AJS does not allow for repeat of a sequence.
I agree, if coded within a CL, STRWCH would not be needed.
From: MIDRANGE-L [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of CRPence
Sent: Saturday, December 06, 2014 12:16 PM
Subject: Re: Retrieve the library name from CPF2113
On 05-Dec-2014 15:17 -0600, Steinmetz, Paul wrote:
I have my WRKWCH working for CPF2113, Cannot allocate library I have
now automated the process of finding the locks on a library, ending
On our R&D LPAR, we have AJS (Advanced Job Scheduler) that deletes all
20+ libraries for an environment.
Following our nightly full Production save, we then refresh these
libraries from Production.
Periodically, not all processes are ended, thus resulting in library
locks, thus the DLTLIB job fails.
The WRKWCH program outputs all the lock to a file
CVTLIBLCK2 LIB(&MSGLIB) OUTLIB(PAULS) /* t */
Reading through the file
ENDJOB JOB(&OLJNBR/&OLUSER/&OLJNAM) OPTION(*IMMED) +
/* RETRY DLTLIB THAT WAS ORIGINALLY LOCKED */
Seems odd to design\use a reactive by-notification approach that is implemented outside of the procedure that might fail to effect a DLTLIB; implemented as a Watch Program (WCHPGM) via Start Watch (STRWCH).
Perhaps that /procedure/ is scripted CL instead of CL code for which conditional logic is unavailable.? Seems like the procedure doing the DLTLIB requests could be coded to _react directly to_ and rectify any failing situation; the recovery processing performed inline to the delete request proccessing could even use\invoke the same logic as described being coded in the WCHPGM of the STRWCH.?
FWiW If I had a need for a Delete Library request to operate so aggressively as to [blindly or at least per unattended algorithm] perofrm ENDJBO requests against any jobs holding the locks, I would probably write a custom command that calls a program to perform the actions according to a requested level of aggressiveness; perhaps including consideration for the value of Library Locking Level
(QLIBLCKLVL) and both the System Library List (QSYSLIBL) and User Library List (QUSRLIBL) if DLTLIB was mandatory, or even the option to allow for Clear Library (CLRLIB) instead. Noting however, that even review of those system values ignores the possibility that active subsystem monitor jobs may have the library assigned for their Subsystem Library (SYSLIBLE); in any case, End Subsystem (ENDSBS) might be required instead of ENDJOB, and for any system jobs an IPL after removing the library from QSYSLIBL and\or changing QLIBLCKLVL would be required for DLTLIB but not CLRLIB.
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a moment to review the archives at http://archive.midrange.com/midrange-l