Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Post In conditions to ControlM from INTRDR/JCL

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
waveal

New User


Joined: 27 Jan 2007
Posts: 5
Location: Manila, Philippines

PostPosted: Wed Oct 26, 2011 1:24 pm    Post subject: Post In conditions to ControlM from INTRDR/JCL
Reply with quote

Hello,

I have a rather weird question. Is it possible to post an IN condition to control M OS/390 from a JCL? The situation is this: I have a job(say, Job A) that is triggered by a transaction and is sent to INTRDR for execution. And then, there is a second job (say, Job B), cyclic, waiting in control M that will pick up the file output of job A.

Job A is triggered every 15 minutes and Job B is scheduled 5 minutes after the theoretical start time of Job A. Sometimes, job A and Job B will run concurrently and Job B fails with a JCL error since the file is not yet created.

I was only thinking of a straight forward solution of limiting the runs of Job B by posting an in condition from job A jcl to controlM(if ever this is possible) but other solutions are most welcome (resource control?)

Thank you in advance.

n.b: I did not design this workflow and I am only supporting the system.
ps. i've read some posts by dick scherrer that uses gdgs as a lookout but this seems to be too taxing on the system (if i were to schedule a lookout job every 5 minutes considering that the file is very critical, the system is shared by several divisions and night batch is running for some divisions during the time my division is online)
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10202
Location: italy

PostPosted: Wed Oct 26, 2011 1:30 pm    Post subject: Reply to: Post In conditions to ControlM from INTRDR/JCL
Reply with quote

why not schedule job b upon the creation of the relevant <trigger> file from job a ?

job b should take care of deleting the <trigger> dataset upon completion

You do not schedule any lookout ... it is the job scheduler that will take care of everything

done properly it will schedule things for any number of job A submissions
( not at the same time )
Back to top
View user's profile Send private message
waveal

New User


Joined: 27 Jan 2007
Posts: 5
Location: Manila, Philippines

PostPosted: Wed Oct 26, 2011 1:36 pm    Post subject:
Reply with quote

Hello Enrico,

Thank you for your suggestion.
Job B actually is a control D report creating job. It picks up the flat file created by Job A and turns it into a cdam report file. Job B triggers another element (control D element) for report decollation and sending to control D PC.

I actually thought of incorporating the steps of Job B into Job A so that it would run as one thorough job but the next question is, how do i trigger the control D element to pick up the cdam file? (which brings me back to square one)
Back to top
View user's profile Send private message
waveal

New User


Joined: 27 Jan 2007
Posts: 5
Location: Manila, Philippines

PostPosted: Wed Oct 26, 2011 1:39 pm    Post subject:
Reply with quote

i think i misunderstoon your post, enrico. is there a way (like a filewatcher) to let Job B run once Job A creates the file?
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed Oct 26, 2011 1:41 pm    Post subject:
Reply with quote

It should all be in the control M documentation
Back to top
View user's profile Send private message
waveal

New User


Joined: 27 Jan 2007
Posts: 5
Location: Manila, Philippines

PostPosted: Wed Oct 26, 2011 1:50 pm    Post subject:
Reply with quote

Hello expat,

we have external triggers in our scheduler but I've only seen samples for TDE transfers. TDE script triggers the job once the file is created as a post processing run. but i havent come across any external triggers coming from a jcl(?)
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Wed Oct 26, 2011 2:17 pm    Post subject:
Reply with quote

Hi,

what happens if job A fails, what tracks it ?

do you have CMEM running on your system ? if yes, you can track the job and on successful completion of job A you can do the usual post processing ie. post a condition to kick off job B.

Your decollating mission will need to consume/delete/clean up the condition is preparation for the next successful run of job A.

Yes, you can post a condition in batch mode using IOACND.


Gerry
Back to top
View user's profile Send private message
waveal

New User


Joined: 27 Jan 2007
Posts: 5
Location: Manila, Philippines

PostPosted: Wed Oct 26, 2011 3:00 pm    Post subject:
Reply with quote

Hello Gerry,

thank you for that. i'll ask my system admin if we have cmem. i'll aslo look for documentation on IOACND.

Thanks again
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Wed Oct 26, 2011 3:06 pm    Post subject:
Reply with quote

Hi,

just check if CMEM started task is running.

Also with CMEM you can track dataset creation to trigger job B.

The best bet is for job A arriving with a TYPRUN=HOLD and CMEM to track it's arrival.

This way you can have full control when job A runs. ie don't start job A until job B and decollating mission have completed.


Gerry
Back to top
View user's profile Send private message
Phrzby Phil

Active Member


Joined: 31 Oct 2006
Posts: 961
Location: Richmond, Virginia

PostPosted: Wed Oct 26, 2011 5:26 pm    Post subject:
Reply with quote

Why not just have the in-cond for B be the creation of A's file that B wants? Then A's status is irrelevant and need not be mentioned in B's scheduling parms.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Thu Oct 27, 2011 4:03 am    Post subject:
Reply with quote

Hi Phil,

I did say
Quote:
Also with CMEM you can track dataset creation to trigger job B.



The only problem with job A running externally to Control-M without a TYPRUN=HOLD is you have no control when job A runs. ie. if you have no initiators available for job A to run or enqueues, you can have a situation where multiple A jobs can run immediately one after the other before B job gets a look in which case it throws the file process out of sequence not to mention the decollating mission or job A fails if the dataset has not been cleaned up by job B.


Gerry
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts DFSORT report with multiple conditions Bill Woodger DFSORT/ICETOOL 9 Wed Jan 20, 2016 2:19 am
No new posts z/OS Upgrade- Post Upgrade Sanity Checks Abid Hasan All Other Mainframe Topics 8 Mon Jun 16, 2014 11:37 am
No new posts Conditions on SORT to avoid extra space vicharapusrinu JCL & VSAM 17 Thu Jan 16, 2014 1:29 pm
No new posts Query for invalid job in INTRDR mohitsaini JCL & VSAM 7 Fri Oct 18, 2013 10:42 pm
No new posts Interesting post on the Beginners and... prino All Other Mainframe Topics 0 Sat Jun 29, 2013 11:55 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us