(I know it's not Friday, but time these days is twisted beyond recognition) I used to work for a bank. One Monday morning, we were told that we needed to provide a disaster recovery platform for another bank with whom we had a mutual support agreement. ASAP. Which was totally news to us. Obviously never tested. They had hit a snag with some kind of upgrade and were completely down.
We were pretty smart, so we carved out some space for them to run their apps in. We got their system restored from tape. It IPLed. They fired up their app, which crashed. We found that the failing program had been linked together with some IBM module that did not match our level of MVS. The problem seemed simple enough. Relink their program with our version of the IBM module. Not so fast. We discovered from their install jobs that they had coded something like this: BANKAPP Lots of code and calls including the IBM module END As long as the program was compiled and linked in the same run, the END statement picked up BANKAPP as entry point and everything was cool. But when run separately, the entry point was indeterminate, so link failed. Source of course was not available so we could not add END BANKAPP Not sure how long we slogged away at this, but before we could bedazzle our way out of the predicament, guest bank got their upgrade completed and no longer needed our feeble assistance. We slunk back to our desks. . . J.O.Skip Robinson Southern California Edison Company Electric Dragon Team Paddler SHARE MVS Program Co-Manager 323-715-0595 Mobile 626-543-6132 Office ⇐=== NEW [email protected] -----Original Message----- From: IBM Mainframe Discussion List <[email protected]> On Behalf Of Steff Gladstone Sent: Thursday, January 21, 2021 6:50 AM To: [email protected] Subject: (External):Re: Isolating a CSECT within a load module *** EXTERNAL EMAIL - Use caution when opening links or attachments *** Thank you Greg, Paul and Max for your informative replies! On Tue, 5 Jan 2021 at 15:12, Massimo Biancucci <[email protected]> wrote: > I tried to develop you hints: > > // EXPORT SYMLIST=* > // SET INPMOD=oldmd > // SET OUTMOD=newmod > // SET INPLIB=myold.lib > // SET OUTLIB=mynew.lib > // SET AMBDSN=AMBLIST3 > // SET DSP='MOD,PASS' DSP='MOD,CATLG' > //*-------------------------------------------------------------------* > //* * > //*------------------------------------------------------------------- > * > //ST010 EXEC PGM=AMBLIST > //SYSPRINT DD DSN=&SYSUID..&AMBDSN,DISP=(&DSP), // > SPACE=(TRK,(5,5),RLSE) //LOADLIB DD DISP=SHR,DSN=&INPLIB > //SYSIN DD *,SYMBOLS=(JCLONLY,SYMBLOG) > LISTIDR DDN=LOADLIB,MEMBER=&INPMOD > /* > //*-------------------------------------------------------------------* > //* * > //*------------------------------------------------------------------- > * > //ST020 EXEC PGM=SORT > //SYSOUT DD SYSOUT=* > //SORTIN DD DSN=&SYSUID..&AMBDSN,DISP=SHR //SORTOUT DD > DSN=&SYSUID..&AMBDSN..CMD,DISP=(&DSP), > // SPACE=(TRK,(5,5),RLSE),DCB=(LRECL=80,RECFM=FB,DSORG=PS) > //SYSIN DD *,SYMBOLS=(JCLONLY,SYMBLOG) > SORT FIELDS=COPY > OUTFIL FNAMES=SORTOUT,REMOVECC, > INCLUDE=(2,10,CH,EQ,C'CSECT: ',AND, > 12,8,CH,NE,C'&OUTMOD'), > OUTREC=(C' REPLACE ',12,8,80:X), > TRAILER1=(' INCLUDE SYSLIB(&INPMOD)',/, > ' NAME &OUTMOD(R)') > /* > //*-------------------------------------------------------------------* > //* * > //*-------------------------------------------------------------------* > //ST030 EXEC PGM=HEWL, > // PARM='LET,XREF,MAP,LIST,NCAL' > //SYSPRINT DD SYSOUT=* > //SYSUT1 DD DSN=&&SYSUT1,SPACE=(1024,(120,120),,,ROUND), > // DCB=BUFNO=1 > //*YSLIN DD DISP=SHR,DSN=J48017.OSET.LOAD(IRXINIT) > //SYSLIB DD DISP=SHR,DSN=&INPLIB > //SYSLMOD DD DISP=SHR,DSN=&OUTLIB(&OUTMOD) > //SYSLIN DD DISP=SHR,DSN=&SYSUID..&AMBDSN..CMD > //*-------------------------------------------------------------------* > //* * > //*------------------------------------------------------------------- > * > //ST040 EXEC PGM=AMBLIST > //SYSPRINT DD SYSOUT=* > //LOADLIB DD DISP=SHR,DSN=&OUTLIB > //SYSIN DD *,SYMBOLS=(JCLONLY,SYMBLOG) > LISTIDR DDN=LOADLIB,MEMBER=&OUTMOD > LISTLOAD DDN=LOADLIB,MEMBER=&OUTMOD > /* > > and it seems it's still working. > I'm sure it's possible to further optimize, anyway I think it's a kind > of tool you use not so often. > Anyway take the two of them as POC. > > Best regards. > Max > > < > https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_c > ampaign=sig-email&utm_content=webmail > > > Mail > priva di virus. www.avast.com > < > https://www.avast.com/sig-email?utm_medium=email&utm_source=link&utm_c > ampaign=sig-email&utm_content=webmail > > > <#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2> > > Il giorno lun 4 gen 2021 alle ore 18:44 Paul Gilmartin < > [email protected]> ha scritto: > > > On Mon, 4 Jan 2021 16:32:47 +0100, Massimo Biancucci wrote: > > > > > >I've tried to use sort to help. > > > > > >// EXPORT SYMLIST=* > > >// SET INPMOD=oldmd > > >// SET OUTMOD=newmod > > >// SET INPLIB=myold.lib > > >// SET OUTLIB=mynew.lib > > > > > I like that sort of parameterizing. It puts the variables up front, > > viewable at a glance. I'd add the AMBLIST2 DSNs to the SET list. > > > > Can something such as "SET DISP={PASS|CATLG} be used to control temp > > vs. permanent workfiles? > > > > >//* * > > >//*---------------------------------------------------------------- > > >---* > > >//ST010 EXEC PGM=IDCAMS > > >//SYSPRINT DD SYSOUT=* > > >//SYSIN DD *,SYMBOLS=(JCLONLY,SYMBLOG) DELETE &SYSUID..AMBLIST2 > > >IF MAXCC=8 THEN SET MAXCC=0 > > >/* > > >//*-------------------------------------------------------------------* > > >//* * > > >//*---------------------------------------------------------------- > > >---* > > >//ST020 EXEC PGM=AMBLIST > > >//SYSPRINT DD DSN=&SYSUID..AMBLIST2,DISP=(,CATLG), > > >// SPACE=(TRK,(5,5),RLSE) > > >//LOADLIB DD DISP=SHR,DSN=&INPLIB > > >//SYSIN DD *,SYMBOLS=(JCLONLY,SYMBLOG) > > > LISTIDR DDN=LOADLIB,MEMBER=&INPMOD > > >/* ... > > My very peculiar preference is to omit the IDCAMS steps and code either: > > //HANDLE DD DSN=&SYSUID..AMBLIST2,DISP=(MOD,CATLG), > > // SPACE=(TRK,(5,5),RLSE) > > //SYSPRINT DD DISP=OLD,DSN=*.HANDLE,VOL=REF=*.HANDLE > > > > Or: > > //HANDLE DD DSN=&SYSUID..AMBLIST2,DISP=(MOD,DELETE), > > // SPACE=(TRK,(5,5),RLSE) > > //SYSPRINT DD DSN=&SYSUID..AMBLIST2,DISP=(MOD,CATLG), > > // SPACE=(TRK,(5,5),RLSE) > > > > But, performance? Is a failing IDCAMS step less overhead than an > > otiose DISP=(MOD,DELETE) etc.? > > > > >I used "no-temp" dataset to better help in understanding the process. > > ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
