Greetings:
I am trying to get the status of the jobs from the Command line and help monitor the jobs without using DS Director.
For this i just loop through all the jobs and run dsjob to get the log details and spool into a text. Then parse this text to derive the required info. This whole process is very consuming (say 2sec/job).
Is there any Universe table/VOC Entry that i can use to derive this quick.
Thanks in Advance.
Regards,
Badhri ...
Get Job Status from Command Line
Moderators: chulett, rschirm, roy
Get Job Status from Command Line
Badhrinath Krishnamoorthy
www.cognizant.com
www.cognizant.com
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Not from the UniVerse command line, unless you know the internal structure in the Repository where status is recorded (it's based on a concept of "resources" - active stages that run in separate processes are also "resources").
You can, however, use the dsjob command from the operating system command line. The -jobinfo option reports job status among other things.
You can, however, use the dsjob command from the operating system command line. The -jobinfo option reports job status among other things.
Code: Select all
dsjob -user userid -password password -jobinfo projectname jobname
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Hi Ray,
Thanks for your input. I tried this dsjob and get the update. But everytime someone wants to know the status of the jobs i need to run this dsjob command for all the jobs which is very time consuming. Is there anyway i can erive the status of the all the jobs in one go?
Badhri ...
Thanks for your input. I tried this dsjob and get the update. But everytime someone wants to know the status of the jobs i need to run this dsjob command for all the jobs which is very time consuming. Is there anyway i can erive the status of the all the jobs in one go?
Badhri ...
Badhrinath Krishnamoorthy
www.cognizant.com
www.cognizant.com
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Nothing that's supplied.
You could write your own wrapper to dsjob. For example:
You could write your own wrapper to dsjob. For example:
Code: Select all
#!/bin/sh
project=myproject # name of your project
for jobname in `dsjob -ljobs $project`
do
jstatus=`dsjob -jobinfo $project $jobname| grep "Job Status" | cut -d: -f2`
echo $jobname: $jstatus
done
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.