osh executer problem and solution ?

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
rameshrr3
Premium Member
Premium Member
Posts: 609
Joined: Mon May 10, 2004 3:32 am
Location: BRENTWOOD, TN

Post by rameshrr3 »

In DataStage command language

execute the following command from administrator after ensuring all users have been disconnected

Code: Select all

CLEAR.FILE &PH&
In Unix, go to the project directory
change to the &PH& subdirectory, and delete files
Once again ensure all users have been disconnected
from data stage

Code: Select all

#cd \&PH\&
#rm *.*
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Background processes are called "phantom" processes in DataStage, for reasons historical. These processes direct their output to files in &PH& which is a subdirectory in the project directory.

Do not use the sledgehammer approach proposed by rameshrr3. Instead use a gentler approach which removes only older records. That way, if there are running jobs, you will not trample on the files to which they are trying to redirect their output.

Code: Select all

find '&PH&' -atime +7 -exec rm {} \;
Beware that "&" and ";" are special characters in the shell, so need to be hard-quoted or escaped in the find command.

The number of files limit limits the number of files a process can have open simultaneously. By setting this to a larger value in dsenv is means that a given DataStage process will be less likely to fail to open a file because it has no more file units available.

:idea: To execute a UNIX command from the Administrator client use the SH command.

Code: Select all

SH -c "find '&PH&' -atime +7 -exec rm {} \;"
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply