IBM Support

IZ84372: UA WINDOWS: SCRIPT DP MAY LEAK MEMORY DUE TO STDERR PROCESSING

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • Severity: 3
    Approver:BEH
    Compid:  5724K1000 Tivoli Universal Agent
    Abstract:UA Windows: SCRIPT DP may leak memory due to STDERR
    processing
    
    Environment:
     ITM 6.2.1 on Windows
     (All versions have the same problem potentially)
    
    Problem Description:
     SCRIPT DP may leak memory and cannot create a new thread.
     UA cannot reconnect to TEMS after disconnection between UA and
    TEMS due to this leaking.
    
    Detailed Recreation Procedure:
     Obvious recreation procedure was not found.
     However, it seems to be caused by using VBScript.
    
    Related Files and Output:
     You can see the following error in RAS1 log.
    
    =====
    "KUMP_LaunchScript") ***** GetExitCodeThread failed for
    hLogThread, Errno 6
    "KUMP_LaunchScript") ***** CloseHandle failed for hLogThread,
    Errno 6
    =====
    
    After disconnection between UA and TEMS,
    
    =====
    "KLXT_CreateThread") Thread creation error: 12
    =====
    

Local fix

  • N/A
    

Problem summary

  • SCRIPT data provider may leak memory and cannot create a new
    thread. UA cannot reconnect to TEMS after disconnection between
    Universal Agent and TEMS due to this leaking.
    
    You can see the following errors in the RAS1 log.
    
     "KUMP_LaunchScript") ***** GetExitCodeThread failed for
     hLogThread, Errno 6
     "KUMP_LaunchScript") ***** CloseHandle failed for hLogThread,
     Errno 6
    
    After disconnection between Universal Agent and TEMS,
    
     "KLXT_CreateThread") Thread creation error: 12
    
    This APAR only applies to UA running on a Windows platform using
    SCRIPT data provider
    

Problem conclusion

  • If the Universal Agent thread processing script's STDERR does
    not complete quickly, Microsoft's TerminateThread() API was
    being called; TerminateThread() leaks memory, so the Universal
    Agent code was changed to not call this Microsoft API.
    
    Code change inserted a 'retry' loop that waits for the STDERR
    thread to complete.
    
    
    Install Actions
    
    In order to gain the effect of the IZ84372 fix, you need to add
    into the KUMENV file the following UA Environment Variable and
    assign it a value of nnn milliseconds.
    
       KUMP_STDERR_WAIT_TIME=100
    
    This value, in milliseconds, is how long UA's SCRIPT data
    provider will wait if 'LogScriptStandardError' thread has not
    completed. The UA will loop up to 5 retries to see if
    'LogScriptStandardError' thread has finished. So for example:
    
      for KUMP_STDERR_WAIT_TIME=100 x 5 = 500 milliseconds ( 0.5
    seconds )
      could result in SCRIPT datsa provider waiting for up to 0.5
    seconds
      for the thread to finish.
    
    The environment may require 'tuning' the value for
    KUMP_STDERR_WAIT_TIME, for example it may need to be 150 or 200.
    Keep in mind the larger the value, the longer the 'wait'
    incurred by the UA's SCRIPT data provider when processing a
    script.
    
    The default value for KUMP_STDERR_WAIT_TIME is zero, which is
    equivalent to not using the environment variable.
    
    
    The fix for this APAR is included in the following maintenance
    vehicle:
        | fix pack | 6.2.1-TIV-ITM-FP0004
        | fix pack | 6.2.2-TIV-ITM-FP0004
    

Temporary fix

Comments

APAR Information

  • APAR number

    IZ84372

  • Reported component name

    UNIVERSAL AGENT

  • Reported component ID

    5724K1000

  • Reported release

    621

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2010-09-05

  • Closed date

    2010-10-07

  • Last modified date

    2011-03-14

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

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

Fix information

  • Fixed component name

    UNIVERSAL AGENT

  • Fixed component ID

    5724K1000

Applicable component levels

  • R621 PSY

       UP

[{"Line of Business":{"code":"LOB45","label":"Automation"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"SSSHL9","label":"Tivoli Universal Agent"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"621"}]

Document Information

Modified date:
07 October 2021