IBM Support

PH64687: CHILD ENCLAVE TERMINATION ATTEMPTS TO FREE FILE DYNAMICALLY ALLOCATED BY THE PARENT ENCLAVE USING AN ENVVAR FOR AMODE64

A fix is available

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • The runtime tracks files allocated dynamically using the
    environment variable method at the region level, but tries to
    free them at enclave termination. In the absence of child
    enclaves this is not a problem.
    
    However, with a child enclave, termination may try to free a
    file still open in the parent enclave, leading to an IKJ56861I
    FILE ... NOT UNALLOCATED, DATA SET IS OPEN failure, to which
    termination responds by deleting the record of the file having
    been allocated. If the parent enclave then reopens the affected
    file, another allocation is attempted, leading to a IKJ56246I
    DATA SET ... NOT ALLOCATED, FILE IN USE, with the open failing
    with file status 98.
    

Local fix

Problem summary

  • ****************************************************************
    * USERS AFFECTED: Users of Enterprise COBOL 6.3 and later      *
    *                 releases running AMODE 64 programs that use  *
    *                 files dynamically allocated through the      *
    *                 COBOL runtime and create nested enclaves     *
    *                 for one or more dynamically called           *
    *                 program(s).                                  *
    ****************************************************************
    * PROBLEM DESCRIPTION: Nested (child) enclave termination      *
    *                      attempts to free files on child         *
    *                      enclave termination of the CALLEE but   *
    *                      the file(s) dynamically allocated       *
    *                      through the COBOL runtime cannot        *
    *                      be freed if it is open in the parent    *
    *                      enclave, and runtime error recovery     *
    *                      removes the record of the file having   *
    *                      been allocated. If record of a file     *
    *                      having been dynamically allocated is    *
    *                      removed, reopening the file attempts    *
    *                      to reallocate it when it is in fact     *
    *                      still allocated, which fails the open.  *
    *                                                              *
    *                      For example, if a child enclave         *
    *                      is created for called COBOL             *
    *                      programs (CALLEE), and the              *
    *                      caller COBOL programs (CALLER) have     *
    *                      files dynamically allocated through     *
    *                      the COBOL runtime open and in           *
    *                      use, on child enclave termination of    *
    *                      the CALLEE, the files dynamically       *
    *                      allocated through the COBOL runtime     *
    *                      in use in the CALLER is                 *
    *                      incorrectly closed and use of that file *
    *                      is lost within the LE process where the *
    *                      multiple enclaves reside.               *
    ****************************************************************
    * RECOMMENDATION: Install the provided PTF.                    *
    ****************************************************************
    The COBOL runtime logic for Nested child enclave (CALLEE)
    termination attempted to free files on child enclave termination
    of the CALLEE for file(s) dynamically allocated through the
    COBOL runtime in the parent enclave (CALLER) and no longer
    made those files accessible for use on an LE process level once
    a child enclave was terminated.
    
    COB0603T/K COB0604T/K
    

Problem conclusion

  • The COBOL runtime logic has been corrected.
    On enclave termination, files dynamically allocated through the
    COBOL runtime are freed only if the files were allocated in
    the same enclave being terminated.
    

Temporary fix

Comments

APAR Information

  • APAR number

    PH64687

  • Reported component name

    LE ENT COBOL LI

  • Reported component ID

    568819812

  • Reported release

    7E0

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2025-01-02

  • Closed date

    2025-01-24

  • Last modified date

    2025-02-03

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

    UI99733 UI99734

Modules/Macros

  • CELQSG04 CELQV004 IGZQAPI  IGZQCA64 IGZQCDA  IGZQINPL IGZQJNI2
    IGZQR004
    

Fix information

  • Fixed component name

    LE ENT COBOL LI

  • Fixed component ID

    568819812

Applicable component levels

  • R7D0 PSY UI99733

       UP25/01/30 P F501

  • R7E0 PSY UI99734

       UP25/01/30 P F501

Fix is available

  • Select the PTF appropriate for your component level. You will be required to sign in. Distribution on physical media is not available in all countries.

[{"Business Unit":{"code":"BU048","label":"IBM Software"},"Product":{"code":"SS6SG3","label":"Enterprise COBOL for z\/OS"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"7E0","Line of Business":{"code":"LOB70","label":"Z TPS"}}]

Document Information

Modified date:
03 February 2025