IBM Support

DataStage sequence job has long delay after regaining control after completion of called script.

Troubleshooting


Problem

For one specific DataStage sequence job, after it calls an external script to perform tasks with OS files, there is an hours-long delay after script completion before DataStage updates the job log with results of the command. 

Resolving The Problem

When a DataStage Sequence uses the external command stage to call an OS command or script, DataStage redirects standard output of the command to a temporary file.    When the command completes, DataStage reads the command output file and then writes to job log both the result code returned by the command, and also the output of the command. 

For the one specific sequence that had an hours-log delay, the external command stage invoked a site-written script which had script tracing enabled (set -vx).  This resulted in very large capture file (230 Megabytes) -- typically output from commands is much smaller (just a few kilobytes).   The DataStage sequence job processes the full output of the command but was not intended to process that much data as command output (the portion written to job log is truncated to 64k, but only after processing the full data), for example: 

Message: SequenceCleanup.JobControl: Executed: exec /scripts/myCleanupScript.sh
… (first 256k of trace output if script had trace enabled)…
[Message truncated to 256000 characters, actual length was 207573333 characters]

Once script tracing is turned off, the output capture file is greatly reduced in size and the sequence now responds immediately with log update upon command completion.

Document Location

Worldwide

[{"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSZJPZ","label":"IBM InfoSphere Information Server"},"ARM Category":[{"code":"a8m50000000L0uQAAS","label":"DataStage->Job Runtime Issues"}],"ARM Case Number":"TS003826653","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF016","label":"Linux"},{"code":"PF033","label":"Windows"}],"Version":"All Version(s)","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
26 June 2020

UID

ibm16240702