IBM Security Z Security

Security for Z

Join this online user group to communicate across Z Security product users and IBM experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  Allocation of custom dataset

    Posted Wed August 02, 2023 07:01 AM

    Hi everyone. Wanted to ask - are there any parameters to prevent job failing if the allocated dataset does not exist (for example - deleted)? I have allocated a few custom dataset - see the code:

    deftype type=INPUT1 nowarn                           
    alloc   type=INPUT1 dsn=DATASET.ONE(FILE1)

    alloc   type=INPUT1 dsn=DATASET.TWO(FILE1)

    alloc   type=INPUT1 dsn=DATASET.THREE(FILE1)
    define  type=INPUT1 text1 as substr(record,9,19)      
                                                        
    newlist type=INPUT1 nopage nodup retain
    select text1='This is just a text'                             
    sortlist text1



    ------------------------------
    Viktorija Kulbaciauskiene
    ------------------------------


  • 2.  RE: Allocation of custom dataset

    Posted Wed August 02, 2023 11:20 AM

    Hi Viktorija,

    There is no construct for that in CARLa.

    You could use a DD=ddname specification instead of a DSN=dsname one to pull the data source specification from the CARLa into the JCL. Perhaps you can find a construction in JCL to check for the existence of the DSNAME then.

    Regards,



    ------------------------------
    Jeroen Tiggelman
    IBM - Software Development and Level 3 Support Manager IBM Security zSecure Suite
    Delft
    ------------------------------



  • 3.  RE: Allocation of custom dataset

    Posted Thu August 03, 2023 03:39 AM

    If you are pointing to a sequential dataset (and not to a member of a PDS), you might be able to use DSNPREF=<the full sequential dsname>.
    In that case, the CARLa runs and simply generates an empty report if the dataset doesn't exist.



    ------------------------------
    Guus Bonnes
    ------------------------------



  • 4.  RE: Allocation of custom dataset

    Posted Fri August 04, 2023 04:18 AM

    Thanks for your replies. With dsn newlist type I'm able to check for datasets which are on specific environment, for example:

    newlist type=dsn 
    select dsn=DATASET.*
    sortlist dsn

    Am I able to check in some way the dataset + it's member?

    for example DATASET.*(FILE1)

    The dataset member FILE1 will always be the same across all environments.



    ------------------------------
    Viktorija Kulbaciauskiene
    ------------------------------



  • 5.  RE: Allocation of custom dataset

    Posted Sun August 06, 2023 10:22 AM
    Edited by Rob van Hoboken Sun August 06, 2023 10:23 AM

    zSecure uses the CKFREEZE file to report on data sets.  Information must be collected into a CKFREEZE using CKFCOLL.  By default, CKFCOLL collects the member names in system critical data sets, unless member name collection is disabled using a PDS=NO command in SYSIN.  You can use the PDSDIR command or the CHECK=DSN command variants to identify other dsnames.  You could check menu option AU.L.0 as an example for specifying CKFCOLL options and directives.

    If member information has been collected, newlist type MEMBER is available.

    ------------------------------
    Rob van Hoboken
    ------------------------------



  • 6.  RE: Allocation of custom dataset

    Posted Mon August 14, 2023 03:14 AM

    Thanks a lot, Rob - is this something must be specified in JCL? I'm interested in something like CHECK=DSN parameter. 

    DSNPREF parameter would work perfectly, but it only analyses sequential datasets

    Including additional dataset in menu option AU.L.0 does not suit me in this case, unfortunately



    ------------------------------
    Viktorija Kulbaciauskiene
    ------------------------------



  • 7.  RE: Allocation of custom dataset

    Posted Mon August 14, 2023 03:57 AM
    Edited by Rob van Hoboken Mon August 14, 2023 03:58 AM

    You must use these directives in the JCL you use to run CKFCOLL, like so

    //COLLECT EXEC PGM=CKFCOLL
    //STEPLIB DD DISP=SHR,DSN=CKR.SCKRLOAD
    //CKFREEZE DD ....
    //SYSIN DD *
    PDSDIR=MY.PDS1
    PDSDIR=MY.PDS2

    A sample of this JCL can be generated from AU.L.0, which you subsequently customize, save and run in your daily plans.

    Alternatively, you can use 

    //COLLECT EXEC PGM=CKFCOLL
    ...
    //SYSIN DD *
    CHECK=DSNPREF=MY.PDS,DSORG=PO

    which should collect member names and calculate a checksum for each of those members.

    Note, the CARLa reports using newlist type=member show the status at the time of the CKFCOLL run, they will obviously not reflect the member information at report time.  Follow the links in my previous post.

    ------------------------------
    Rob van Hoboken
    ------------------------------