|
|
| [Home] [Products] [Support] [Documents] [Partners] [Contact Us] [Search] | © 1998-2008 Gilbert Saint-Flour |
OverviewSCANPDS is a multi-function utility program which scans partitioned data sets (PDS & PDSE), lists directories, cross-references the members they contain, and prints records matching specified search arguments. SCANPDS runs in the TSO/E environment (batch or on-line) on MVS/ESA, OS/390 and z/OS. SCANPDS is a high-performance tool designed to help programmers, consultants and auditors obtain quick answers to a variety of questions, such as the following:
|
SCANPDS performs the following:
SCANPDS supports PDS and PDSE libraries and does not normally update the "last-reference" date in the data set's VTOC entry (format-1 DSCB). SCANPDS is designed for speed and uses various techniques to reduce run time, I/O activity, and CPU consumption.
SCANPDS is an affordable product. A free, time-limited version is available for evaluation. Sample output reports are available for viewing.
SCANPDS is a TSO/E command and standard TSO/E rules for command syntax apply. Below is a list of options and parameters which can be specified. Please refer to the sample JCL for coding examples.
| SCANPDS | (defaults) |
| (library filter keys) | Mandatory |
| EXCLUDE(exclude filters) | n/a |
| MEMBERS(member filters) | * |
| EXCLUDEMEMBERS(member filters) | n/a |
| USERID(user-ID filters) | n/a |
| EXCLUDEUSERID(user-ID filters) | n/a |
| CATALOG(catalog name) | n/a |
| ENTTYPE(catalog entry types) | A |
| VOLUMES(volume list) | n/a |
| FROM(from-date) | n/a |
| TO(to-date) | n/a |
| FIND(search strings) | n/a |
| BOUNDS(n,m) | 1,&LRECL |
| CAPS|ASIS | ASIS |
| LANGUAGE(ASM|COBOL|JCL) | n/a |
| FIRST|FIRST(n)|LAST|ALL | ALL |
| PREFIX|SUFFIX|WORD | n/a |
| INSYNC|SUPERC|PDSM18 | INSYNC |
| MBRSEQ(NAME|TTR) | See Comments |
| MOUNT|NOMOUNT | NoMount |
| RECALL|NORECALL | NoRecall |
| RACHECK|NORACHECK | Racheck |
| FORMAT1|FORMAT2|FORMAT3 | Format2 |
| DUPLICATES|NODUPLICATES|ALL | ALL |
| LINKDATE|NOLINKDATE | NoLinkdate |
| LoadLibraries(EVEN|ONLY|NONE) | EVEN |
| PACKED|NOPACKED | n/a |
| UNPACKED|NOUNPACKED | n/a |
| PACKERROR|NOPACKERROR | n/a |
| EMPTY|NOEMPTY | n/a |
| IOERROR|NOIOERROR | n/a |
| PUTLINE|SYSPRINT(dsname) | See comments |
| LastReferenceDate(Keep|Update) | Keep |
| SortLibraryList | See comments |
| MAXTASKS(n) | 20 |
SCANPDS does not prefix the TSO user ID or prefix to the data set names. If a data set name is prefixed with "&SYSUID.", then SCANPDS replaces "&SYSUID." with the current job's owner ID.
SCANPDS detects data sets migrated by HSM, FDR/ABR and CA-DISK and ignores them unless the RECALL option is specified. Specifying RECALL(DISK), RECALL(TAPE) or RECALL(BOTH) recalls data sets migrated to disk, tape, or both, respectively. Specifying RECALL is equivalent to RECALL(BOTH). As expected, specifying RECALL has a severe impact on performance, particularly when data sets have to be recalled from tape.
SCANPDS fully supports members in ISPF PACKED format. When the PACKED, UNPACKED or PACKERROR options are specified, SCANPDS reads members to identify those in PACKED format, members which are not in PACKED format, or members in PACKED format for which the unpacking routine detects an error. Specifying the PACKED, UNPACKED or PACKERROR options increases I/O activity; specifying PACKERROR also increases CPU consumption.
The FIND option automatically unpacks packed members before searching for specified arguments and displays unpacked records on the FINDOUT data set.
SCANPDS does not currently support ALIAS entries in the catalog.
SCANPDS currently ignores the ALIAS bit in directory entries. As a result, those entries are supported like non-ALIAS members.
The FIND option searches PDS and PDSE members for specified arguments; matching records are printed to the FINDOUT data set. Specifying the FIND option increases I/O activity and CPU consumption.
FIND works in association with a set of related options, namely BOUNDS, WORD, PREFIX, SUFFIX, CAPS, ASIS, FIRST, LAST, ALL and LANGUAGE. Except for LANGUAGE, FIND and associated options work like the corresponding options of the ISPF and SDSF FIND commands.
The FIRST(n) or LAST(n) options (which do not exist in the FIND commands of ISPF or SDSF) instruct SCANPDS to print the first (or last) n matching records for each member. FIRST and LAST are equivalent to FIRST(1) and LAST(1), respectively.
The LANGUAGE(ASM), LANGUAGE(COBOL) or LANGUAGE(JCL) options indicate that comment lines should not be searched for matching arguments. Assembler comments are identified by the presence of an asterisk in pos 1 or 2 of the record. COBOL comments are identified by the presence of an asterisk or a slash in pos 7 of the record. JCL comments are identified by the presence of an asterisk in pos 3 of the record.
FIND operates on load-libraries in PDS or PDSE format. However, results from a load-library search may be confusing, as the matching arguments may not always appear in the FINDOUT output.
The FINDOUT data set is used in conjunction with the FIND option of SCANPDS. When records matching the FIND arguments are found, they are printed to the FINDOUT DD. The default DCB attributes for FINDOUT are RECFM=VBA,LRECL=260. If matching records can be longer than 255 bytes, then an appropriate value equal to 5 plus the length of the longest matching record must be specified on the FINDOUT DD, e.g. LRECL=1005 will accomodate 1000-byte records. The RECFM for FINDOUT is always set to VBA and cannot be changed.
By default, the format of the output written to FINDOUT is similar to that produced by the INSYNC utility; for example, here is some of the output produced by the SCANPDS GSFSOFT.ESA43.MACLIB FIND(ASCB) WORD MEM(IHA*) XMEM(IHAASCB) command:
IHAASEO ----------- GSFSOFT.ESA43.MACLIB ------------------------------------ ASEOSTKN DS XL8 64-bit stoken of new ASCB ASEOASCB DS A ASCB of new address space * 3 ASEOSTKN BIT(64), /* 64-bit stoken of new ASCB */ * 3 ASEOASCB PTR(31), /* ASCB of new address space */ IHAASSB ----------- GSFSOFT.ESA43.MACLIB ------------------------------------ .* $L9=ASCB HBB4410 880404 PD16BN: ASCB VSCR SUPPORT ASSBASCB DS A ADDRESS OF ASCB. @L9C * 2 ASSBASCB PTR(31), /* ADDRESS OF ASCB. @L9C*/ IHAASTE ----------- GSFSOFT.ESA43.MACLIB ------------------------------------ * ASCB ADDRESS @L2A * ASCB ADDRESS. @L2C*/ IHAASVT ----------- GSFSOFT.ESA43.MACLIB ------------------------------------ * CONTAINS ADDRESS OF ASCB. IF NOT * CONTAINS ADDRESS OF ASCB. IF NOT IHAASXB ----------- GSFSOFT.ESA43.MACLIB ------------------------------------ */* control. The ASXB is swappable, and the ASCB is not. */
When the SUPERC option is specified along with FIND, the format of the output written to FINDOUT is similar to that produced by the SEARCHFOR command of the IBM SUPERC utility, as shown below:
GSF Utilities - SCANPDS R401I Monday 27 Dec 2004 (2004.362) 16.36
LINE-# SOURCE SECTION SRCH DSN: GSFSOFT.ESA43.MACLIB
IHAASEO --------- STRING(S) FOUND -------------------
38 ASEOSTKN DS XL8 64-bit stoken of new ASCB
39 ASEOASCB DS A ASCB of new address space
53 * 3 ASEOSTKN BIT(64), /* 64-bit stoken of new ASCB */
54 * 3 ASEOASCB PTR(31), /* ASCB of new address space */
IHAASSB --------- STRING(S) FOUND -------------------
98 .* $L9=ASCB HBB4410 880404 PD16BN: ASCB VSCR SUPPORT
291 ASSBASCB DS A ADDRESS OF ASCB. @L9C
582 * 2 ASSBASCB PTR(31), /* ADDRESS OF ASCB. @L9C*/
IHAASTE --------- STRING(S) FOUND -------------------
159 * ASCB ADDRESS @L2A
262 * ASCB ADDRESS. @L2C*/
IHAASVT --------- STRING(S) FOUND -------------------
120 * CONTAINS ADDRESS OF ASCB. IF NOT
199 * CONTAINS ADDRESS OF ASCB. IF NOT
IHAASXB --------- STRING(S) FOUND -------------------
50 */* control. The ASXB is swappable, and the ASCB is not. */
When the PDSM18 option is specified along with FIND, the format of the output written to FINDOUT is similar to that produced by the PDSM18 utility (PDSMAN), as shown below:
GSF Utilities - SCANPDS R401I Monday 27 Dec 2004 (2004.362) 16.36 ** PDSM18 ** SYS1 GSFSOFT.ESA43.MACLIB NO TARGET STRINGS FOUND IN MEMBER IHAABDPL NO TARGET STRINGS FOUND IN MEMBER IHAABEPL NO TARGET STRINGS FOUND IN MEMBER IHAACEE NO TARGET STRINGS FOUND IN MEMBER IHAAE NO TARGET STRINGS FOUND IN MEMBER IHAAQAT NO TARGET STRINGS FOUND IN MEMBER IHAARL FLG LINENO --- HIT(S) FOUND FOR MEMBER IHAASEO --- HIT 38 ASEOSTKN DS XL8 64-bit stoken of new ASCB HIT 39 ASEOASCB DS A ASCB of new address space HIT 53 * 3 ASEOSTKN BIT(64), /* 64-bit stoken of new ASCB */ HIT 54 * 3 ASEOASCB PTR(31), /* ASCB of new address space */ FLG LINENO --- HIT(S) FOUND FOR MEMBER IHAASSB --- HIT 98 .* $L9=ASCB HBB4410 880404 PD16BN: ASCB VSCR SUPPORT HIT 291 ASSBASCB DS A ADDRESS OF ASCB. @L9C HIT 582 * 2 ASSBASCB PTR(31), /* ADDRESS OF ASCB. @L9C*/ FLG LINENO --- HIT(S) FOUND FOR MEMBER IHAASTE --- HIT 159 * ASCB ADDRESS @L2A HIT 262 * ASCB ADDRESS. @L2C*/ FLG LINENO --- HIT(S) FOUND FOR MEMBER IHAASVT --- HIT 120 * CONTAINS ADDRESS OF ASCB. IF NOT HIT 199 * CONTAINS ADDRESS OF ASCB. IF NOT FLG LINENO --- HIT(S) FOUND FOR MEMBER IHAASXB --- HIT 50 */* control. The ASXB is swappable, and the ASCB is not. */
SCANPDS runs as a TSO command on-line or in batch. The following sample job stream shows how to set up a TMP job step to execute several SCANPDS commands.
//SCANPDS3 JOB (acct#),'PDS XREF',CLASS=A,MSGCLASS=X,COND=(0,NE)
//*
//* Cross-Reference MVS Libraries
//*
//PDSSCAN EXEC PGM=IKJEFT01
//STEPLIB DD DSN=<SCANPDS Load Library>,DISP=SHR
//SYSTSPRT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//FINDOUT DD SYSOUT=*
//SYSTSIN DD *
/* List the directory for SYS1.MACLIB */
SCANPDS SYS1.MACLIB
/* List duplicate members in PROD.LOADLIB and STAGE.LOADLIB
SCANPDS (PROD.LOADLIB STAGE.LOADLIB) DUPLICATES
/* List duplicate IEF anf IGG load-modules in system libraries,
/* along with the corresponding link-edit dates
SCANPDS (LINKLIST LPALIST) MEMBERS(IEF* IGG*) DUPL LINKDATE
/* Scan JCL libraries to locate packed members
/* Recall migrated libraries.
SCANPDS (GSFSOFT.**.*JCL*.** PRJ144.JCL*.**) PACKED RECALL
/* Search all PROD.** and STAGE.** source libraries in the catalog
/* for members modified by GSFSOFT and STAFF*. Scan those members for
/* records containing the 'CP3UU7J' or 'CP4RS4D' character strings.
/* Ignore COBOL Comment lines.
SCANPDS (PROD.** STAGE.**) +
USERID(GSFSOFT STAFF*) +
FIND(CP3UU7J CP4RS4D) +
LANG(COBOL)
/* Cross-reference duplicate members whose names match IEC* and *JEK*
/* display load-module link-edit dates
SCANPDS (**.LOAD* **.LINK* **.PARMLIB) +
EXCLUDE(SYS%.** DLIB.**) +
MEMBERS(IEC* *JEK*) +
DUPLICATES +
LINKDATE
/* Search system and DLIB source libraries for IHA* and IGG*
/* members which contain the 'PSA' or 'ASCB' character strings
/* in pos 8 through 44 of each record.
/* Ignore assembler comment lines with '*' in pos 1 or 2.
/* Print only the first two matching records of each member.
SCANPDS (SYS1.AOS* SYS1.MACLIB SYS1.MODGEN) +
EXCLUDE(SYS1.AOS34 SYS1.AOS5* ) +
LOADLIB(NO) +
MEMB(IHA* IGG*) +
FIND('PSA' 'ASCB') +
BOUNDS(8,44) +
LANG(ASM) +
FIRST(2)
/* List PARMLIB and link-list members updated during
/* the first seven days of February 2004.
SCANPDS (parmlib linklist) from(20040201) to(20040207)
/* List members in all SYS%.** uncatalogued data sets on specified DASD volumes
SCANPDS SYS%.** VOL(Z6RES1 Z6RES2 Z6USS1 Z6USS2)
/*
Sample output listings produced by SCANPDS are available here and here.
Search key-words: ibm mvs os/390 os390 z/os zos tso ispf list directory list directories liste listing global search members searching pds mass scan text plus scanning locate locating cross-reference crossreference xref crossref cross-ref idrdata create created modify change modified changed pds pdse pds/e dataset datasets mbrxref2 generic wildcard wildcards wild-card wild-cards partially-qualified fully-qualified jcl job stream listds listpds pdslist listdir iehlist srchfor replacement masse system-wide sequential