How to fetch all entries of job log from unix?

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
zulfi123786
Premium Member
Premium Member
Posts: 730
Joined: Tue Nov 04, 2008 10:14 am
Location: Bangalore

How to fetch all entries of job log from unix?

Post by zulfi123786 »

Can anyone help me with fetching all entries of job log from unix. I need to grep for a particular entry from the log.

Thanks
Sainath.Srinivasan
Participant
Posts: 3337
Joined: Mon Jan 17, 2005 4:49 am
Location: United Kingdom

Post by Sainath.Srinivasan »

Did you try dsjob with loginfo
gssr
Participant
Posts: 243
Joined: Fri Jan 09, 2009 12:51 am
Location: India

Post by gssr »

Code: Select all

dsjob -logsum <Project> <Job_name>
RAJ
zulfi123786
Premium Member
Premium Member
Posts: 730
Joined: Tue Nov 04, 2008 10:14 am
Location: Bangalore

Post by zulfi123786 »

Thank you .....
I have one more query here....

I was trying to insert a warning into the log using call DSLogWarn ("[IBM][CLI Driver][DB2/AIX64] SQL1476N The current transaction was rolled back because of error -964. SQLSTATE=40506","MyRoutine")

but i am facing problem while insertin double quotes into the message tried doing with \" but didnot work any ideas?
zulfi123786
Premium Member
Premium Member
Posts: 730
Joined: Tue Nov 04, 2008 10:14 am
Location: Bangalore

Post by zulfi123786 »

And One more question,

How to retreive only the last run log events, is there any built in funtionality?

Is it possible to fetch the Log events with one event in one line rather than all concatenated onto one line?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

There are other options for retrieving the event ID of the most recent log event of particular type, and for retrieving the detail of any particular event.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
zulfi123786
Premium Member
Premium Member
Posts: 730
Joined: Tue Nov 04, 2008 10:14 am
Location: Bangalore

Post by zulfi123786 »

Yes I guess you are speaking about the dsjob -lognewest and dsjob -logdetail......

But here the requirement is to fetch all WARNIGS for the last run , this can be impelented by fetching the newest log event before and after the job run and then using the dsjob -logdetail to fetch all entries lying between the above said event numbers, but -logdetail i guess doesnot give the flexibility to fetch only WARNINGS it dumps all events

-logsum gives the fexibility to fetch only WARNINS but it is not possible to restrict the scope between two Event Numbers .

Above all both the commands dump all information into single line making the task more complicated.
Sainath.Srinivasan
Participant
Posts: 3337
Joined: Mon Jan 17, 2005 4:49 am
Location: United Kingdom

Post by Sainath.Srinivasan »

Get the logsum or lognewest to give you the id and find rows with id greater that the newest start.

Alternatively you can get from RT_LOGnnn sets browsing in descending order.
Post Reply