Script for clearing logs

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
kool_cons
Participant
Posts: 68
Joined: Thu Jul 07, 2005 3:41 pm

Script for clearing logs

Post by kool_cons »

HI,
I NEED TO CLEAR OUT THE LOGS FOR MULTI INSTANCE JOBS WITHOUT USING DIRECTOR. SO COULD YOU PLEASE GIVE ME THE SCRIPT FOR CLEARING LOGS IN UNIX IF YOU HAVE. ALSO SUGGEST ME WHAT ARE THE OTHER WAYS OF CLEARING LOGS.
I WOULD APPRECIATE YOUR HELP.
kduke
Charter Member
Charter Member
Posts: 5227
Joined: Thu May 29, 2003 9:47 am
Location: Dallas, TX
Contact:

Post by kduke »

I am not sure you can do it. I know what to delete but the Director is not notified. You have to logout of the project and then log back in. There is some trick I do not know. The instance ids are stored in RT_STATUS and RT_LOG. The ones in RT_STATUS are the active ones. RT_LOG are historical.
Mamu Kim
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Can't be done from UNIX. Job logs are database tables in the Repository database. Therefore you would need to be working in the database environment (dssh). Second, you would need knowledge of how instances are identified in the RT_STATUSnn and RT_LOGnn tables; this knowledge is not in the public domain.

Please explain why you need to clear out the logs without using Director - I am bemused by this assertion. The Director is a client tool supplied for just this kind of task.

Perhaps you could research it. Enable server side tracing, open Director (you will get a warning that tracing is enabled). Clear the log for a job instance. Stop tracing. The trace file will contain all of the helper subroutine calls that were involved. From that you may be able to figure out a mechanism for doing what you want.

But I really don't think you need to. :wink:
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