DATASTAGE - Commands To Delete Files in &PH& Directories in IBM InfoSphere DataStage
DATASTAGE - Commands To Delete Files in &PH& Directories in IBM InfoSphere DataStage
Question
How should we manage cleaning up the &PH& directories for my DataStage projects? Can the process be
automated?
Cause
Files in the &PH& directories under DataStage project directories store runtime information when jobs are run
and need to be cleared out periodically.
Answer
To clear the &PH& directory from within DataStage:
1. Ensure there are no DataStage jobs running anywhere on the system by running "ps -ef | grep DSD"
2. From the DataStage Administrator, go to the Projects page, select the project whose file you want to
clear and click the Command button. The Command Interface dialog box opens.
3. Type the following into the command field: CLEAR.FILE &PH& (all uppercase)
You can also remove the contents of the &PH& directory using the rm command. You can create a shell script
to manually delete the files. To ensure there are no locks only delete files that are from finished jobs by
ensuring the files are older then the longest running job. Generally you can delete files older then a week.
** Important **
Please only delete the contents of &PH& directory and not the &PH& directory itself.
You will find a directory for the &PH& in each project that you have created on that server.
You must not remove any contents or directories for the following:
DS_TEMP*
RT_BP*.O
RT_BP*
RT_LOG*
RT_STATUS*
RT_CONFIG*
These directories/files are related to the jobs within your projects that you are running on the server and if you
manually remove or edit any of these files you are likely to corrupt the jobs and possibly the projects. These
directories exist for each job that has been created within your project. You could ask your developers to
review if there are any jobs that are no longer used and can be removed using the DataStage clients.
Document Information
More support for:
IBM InfoSphere DataStage (https://www.ibm.com/mysupport/s/topic/0TO500000002CtuGAE)
Software version:
9.1.2.0, 8.7, 8.5, 11.5, 11.3.1.2
Operating system(s):
AIX, HP-UX, Linux, Solaris
Document number:
413933
Modified date:
16 June 2018