Status of DS JObs
Moderators: chulett, rschirm, roy
Status of DS JObs
HI,
How do we know that a dsjob is in compile state or uncompiled state?
I know the following methods, please let me know if you have any other.
1) From the director we see the status of the job compiled or not.
The reason why need this is that when we are moving the code from one system to the other, if the job is in uncompiled state that particular job can not be moved.
would like to know if there is any mechanism by which i can test before hand that all the jobs are in compile state before moving the jobs from one env to other env.
How do we know that a dsjob is in compile state or uncompiled state?
I know the following methods, please let me know if you have any other.
1) From the director we see the status of the job compiled or not.
The reason why need this is that when we are moving the code from one system to the other, if the job is in uncompiled state that particular job can not be moved.
would like to know if there is any mechanism by which i can test before hand that all the jobs are in compile state before moving the jobs from one env to other env.
Regards,
Shree
785-816-0728
Shree
785-816-0728
How are you 'moving' jobs? There's no restriction that says it 'cannot be moved' if it is not compiled - unless you've got no way to compile it wherever you are moving it to?
Checking visually via the Director is probably the simplest. I guess you could also use the MJC or Multi-Job Compiler in the Manager, it can easily show you all 'uncompiled' jobs and then optionally compile them for you.
Checking visually via the Director is probably the simplest. I guess you could also use the MJC or Multi-Job Compiler in the Manager, it can easily show you all 'uncompiled' jobs and then optionally compile them for you.
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers
You can check the status of DataStage job from command prompt. Execute following commands:
# Set DataStage Environment
$ cd `cat /.dshome`
$ . ./dsenv
$ cd bin
$ dsjob -jobinfo <DataStage Project Name> <DataStage Job Name>
This output of command would look like following:
Job Status : RUN OK (1)
Job Controller : not available
Job Start Time : Thu Dec 7 16:43:10 2006
Job Wave Number : 2
User Status : not available
Job Control : 0
Interim Status : NOT RUNNING (99)
Invocation ID : not available
Last Run Time : Thu Dec 7 16:43:14 2006
Job Process ID : 0
Invocation List : C001_ArchGenData
Hope it helps........
# Set DataStage Environment
$ cd `cat /.dshome`
$ . ./dsenv
$ cd bin
$ dsjob -jobinfo <DataStage Project Name> <DataStage Job Name>
This output of command would look like following:
Job Status : RUN OK (1)
Job Controller : not available
Job Start Time : Thu Dec 7 16:43:10 2006
Job Wave Number : 2
User Status : not available
Job Control : 0
Interim Status : NOT RUNNING (99)
Invocation ID : not available
Last Run Time : Thu Dec 7 16:43:14 2006
Job Process ID : 0
Invocation List : C001_ArchGenData
Hope it helps........
Assume everything I say or do is positive
You can probably script it. Do a dsjob -ljobs to get all the jobs, read it one by one and pass it to dsjob -report or dsjob -log and grep for 'Job Status'. You can also check if its anything other than 1 or 2 then you can load the job name in a seperate file. A few lines of scripting.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
Thanks for the responses.
-Jobinfo will give the jobinfo.
But my requirement is that from the unix console is there any means by which i can know if the job(present state of the jobs) is in compiled state or not.
JobInfo will help me partially. If the job is compiled and run then definetly it helps me to know that the job is in compiled state.
But if I compile and don't run, then there isn't any means by whihc I can know that the job is in compile state or not.
Just want to understand if there is any means by which I can know that .
Thanks In advance.
-Jobinfo will give the jobinfo.
But my requirement is that from the unix console is there any means by which i can know if the job(present state of the jobs) is in compiled state or not.
JobInfo will help me partially. If the job is compiled and run then definetly it helps me to know that the job is in compiled state.
But if I compile and don't run, then there isn't any means by whihc I can know that the job is in compile state or not.
Just want to understand if there is any means by which I can know that .
Thanks In advance.
Regards,
Shree
785-816-0728
Shree
785-816-0728
Well if its in a runnable state then you "dsjob -report" will give you either Job status = 1 or 2 or 99. 99 (Not running) will tell you that its in a compiled state. If you get
"ERROR: Failed to open job
Status code = -1004"
That means its not in a runnable state.
Thanks for the clarification kumar, your right, -log is to write to the log rather than to retrieve it.
"ERROR: Failed to open job
Status code = -1004"
That means its not in a runnable state.
Thanks for the clarification kumar, your right, -log is to write to the log rather than to retrieve it.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
-report is as good as the jobinfo but gives much more details then the jobinfo.
It has got three return values as jobinfo
1 - finished OK
2 - finished with Warnings
3- Aborted.
99- Job not running.
I understand if the stats of 1-3 indicates that the job is in executable form, that implies that it is has been compiled.
Both these -report and -jobinfo take the status of the job from the previous runs.
Let me explain what is happening in my case.
We test the entire job. that mean a status of 1-3 will be displayed if i use -report or -jobinfo.
I send a request to delivery team to pick up for releasing it to other env.
in between sending the mail and before delivery people picking up the job some one just changes the annotation of the job for some reason. So it goes into uncompile state. Due to which the migration of job fails.
but at this time if i run the jobinfo or -report then it will give me the previous status of the job but not the current status.
Hope i am clear enough this time.
with this back ground now I would like to know is there any method by which i can know the status of the job before releasing.
Thanks
It has got three return values as jobinfo
1 - finished OK
2 - finished with Warnings
3- Aborted.
99- Job not running.
I understand if the stats of 1-3 indicates that the job is in executable form, that implies that it is has been compiled.
Both these -report and -jobinfo take the status of the job from the previous runs.
Let me explain what is happening in my case.
We test the entire job. that mean a status of 1-3 will be displayed if i use -report or -jobinfo.
I send a request to delivery team to pick up for releasing it to other env.
in between sending the mail and before delivery people picking up the job some one just changes the annotation of the job for some reason. So it goes into uncompile state. Due to which the migration of job fails.
but at this time if i run the jobinfo or -report then it will give me the previous status of the job but not the current status.
Hope i am clear enough this time.
with this back ground now I would like to know is there any method by which i can know the status of the job before releasing.
Thanks
Regards,
Shree
785-816-0728
Shree
785-816-0728
I am new to DS jobs can u explain how to process from scratc
please tell me detail about the dsjobs from scratch
Welcome anisubim - but you really need to start your own post, not jump on the end of someone else's post please. And in your new post, clarify if you mean 'dsjob' the command line function or if you literally mean 'DataStage jobs' in general.
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers
Since we are referring to 'dsjob -jobinfo', I assume you are looking for dsjob function that available in command line. The best place to start with would be "Parallel Job Advanced User Guide". Under "Command Line Inerface".
Impossible doesn't mean 'it is not possible' actually means... 'NOBODY HAS DONE IT SO FAR'
I need dsjobs commandline process in datastage
please kindly reply, because i am implementing these steps in my project
Re: I need dsjobs commandline process in datastage
Tell us, what exactly you are looking for and what you want to know.anisubim wrote:please kindly reply, because i am implementing these steps in my project
Impossible doesn't mean 'it is not possible' actually means... 'NOBODY HAS DONE IT SO FAR'