Job in running status, invoked again due to scheduler

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
harryhome
Participant
Posts: 112
Joined: Wed Oct 18, 2006 7:10 am

Job in running status, invoked again due to scheduler

Post by harryhome »

Hi

In 8.1, We are scheduling jobs to run at perticular time daily. What will happen if some job takes more than 24 hr on a particular, then in next schedule when it gets invoked again, it will be already in running state. what will happen to next run then?
priyadarshikunal
Premium Member
Premium Member
Posts: 1735
Joined: Thu Mar 01, 2007 5:44 am
Location: Troy, MI

Post by priyadarshikunal »

It won't get invoked.

But thats where Job Control, Scripts, Enterprise scheduler comes in to picture. Out of curiosity, why you want to schedule a job daily which may take more than 24 hrs?
Priyadarshi Kunal

Genius may have its limitations, but stupidity is not thus handicapped. :wink:
harryhome
Participant
Posts: 112
Joined: Wed Oct 18, 2006 7:10 am

Post by harryhome »

Actually Job will not take 24 hrs normally but in worst case if data is huge then we need to know how it goes for next day schedule. If its not getting invoked then its status will not be aborted, right?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

DataStage will not permit a job - other than a multi-instance job with a different invocation ID - to be started if that job's current status is Running. The error code is DSJE.BADSTATE.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Sainath.Srinivasan
Participant
Posts: 3337
Joined: Mon Jan 17, 2005 4:49 am
Location: United Kingdom

Post by Sainath.Srinivasan »

The job / sequence will fail as it cannot initiate the child job.

Why don'y you use the multi-instance property ? Ofcourse you need to change the dataset names appropriately and pass correct date ranges.

Alternatively, you can include the job in a sequence with a 24hr sleep and the job both joining into a sequencer with ALL as its property. The 24 hr sleep must have its own cycle.

Also you can create a multi-instance sequence that will be initiated everyday which will check the status of previous sequence to be 'Finished'.
priyadarshikunal
Premium Member
Premium Member
Posts: 1735
Joined: Thu Mar 01, 2007 5:44 am
Location: Troy, MI

Post by priyadarshikunal »

Scheduler wont be able to Start the job. In such cases while in sequences, you get error 'Job not in runnable state (compiled not running)' or similar. But when its from the scheduler, you wont get error and however the DSJob command will exit with error.

Its easy to verify the same! Schedule a job which takes atleast 10 mins twice with 5 min difference.
Priyadarshi Kunal

Genius may have its limitations, but stupidity is not thus handicapped. :wink:
Post Reply