Get Running jobs list

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
Ramani
Participant
Posts: 58
Joined: Mon Oct 08, 2007 1:51 am

Get Running jobs list

Post by Ramani »

How to get running jobs list for a project. Is there a direct way. Or should I list all the jobs name from the project and check the status of each job in loop.

What is the quickest way to get this list, considering the response time doing this in loop would take more time?

Basically, I am trying to find out whether the Datastage server is idle meaning, no jobs are running currently considering all the projects in that server...

Thanks
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Unless you need the precise status of every job, I wouldn't bother to loop thru them all. Sounds like a quick "ps -ef |grep phantom| grep -v grep" could get you what you need.
-craig

"You can never have too many knives" -- Logan Nine Fingers
nagarjuna
Premium Member
Premium Member
Posts: 533
Joined: Fri Jun 27, 2008 9:11 pm
Location: Chicago

Post by nagarjuna »

Checking in director manually , Using dsjob -jobstatus or ps -aef | grep phamtom | grep -v grep | wc -l .
Nag
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Use Director status view, disable display of Category and sort by status (click in the grid row header to sort). You can print this report, or print to file.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Ramani
Participant
Posts: 58
Joined: Mon Oct 08, 2007 1:51 am

Post by Ramani »

Director would be a manual process and switching projects manually would take time.

So I would prefer to use the ps unix command. But the question what I have for ps command is that, if the team has opened the jobs in designer, will this ps command bring those processes as well?

Thanks
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

No, you'd have to search for something else to find things like that. Since 'phantom' is a background process for a running job, that's all you'll find.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Ramani
Participant
Posts: 58
Joined: Mon Oct 08, 2007 1:51 am

Post by Ramani »

Thanks chulett.

I was just wondering whether the jobs opened in designer would also come as part of the ps phantom. If this does not bring the designer process, then I am happy.

Because, I am trying to find only the jobs that are running. Thanks for the help, I will check this.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Ramani wrote:Director would be a manual process and switching projects manually would take time.

So I would prefer to use the ps unix command. But the question what I have for ps command is that, if the team has opened the jobs in designer, will this ps command bring those processes as well?

Thanks
These are new requirements. The original question merely asked for the quickest way. Wanna race?
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 »

As per my understanding, only the server jobs run with the phantom process what i am not sure is will a grep on 'phantom' capture the running PX jobs?
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Easy enough to check.
-craig

"You can never have too many knives" -- Logan Nine Fingers
priyadarshikunal
Premium Member
Premium Member
Posts: 1735
Joined: Thu Mar 01, 2007 5:44 am
Location: Troy, MI

Post by priyadarshikunal »

zulfi123786 wrote: will a grep on 'phantom' capture the running PX jobs?
Yes, It will capture the PX jobs as well.
Priyadarshi Kunal

Genius may have its limitations, but stupidity is not thus handicapped. :wink:
invincibleDeepak
Participant
Posts: 14
Joined: Sun Jun 07, 2009 12:26 pm
Location: Mumbai

Post by invincibleDeepak »

I would just want to clarify on this that sometimes I have found phantom process on Unix server with parent process as root and job had completed long back. Sso, isn't it not displaying correct result.
regards
Deepak Kumar
Datastage Developer
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Different issue, and I would question the fact that the job truly 'finished' if there are still processes associated with it.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply