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
 

 

OPC rerun failed job

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IBM Tools
View previous topic :: :: View next topic  
Author Message
Valdis Ozolins

New User


Joined: 09 Dec 2010
Posts: 1
Location: Leeds, West Yorkshire, England

PostPosted: Sat Dec 11, 2010 3:57 am    Post subject: OPC rerun failed job
Reply with quote

In OPC, Is there a way to re run a failed job via a batch process? I have looked at the Control Language (OCL) & the Batch Command Interface Tool but can’t find a way to do this.
[/Search]
Back to top
View user's profile Send private message

KannanChinna

New User


Joined: 14 Feb 2011
Posts: 3
Location: Chennai

PostPosted: Tue Feb 15, 2011 10:15 pm    Post subject: reply
Reply with quote

sjr is the command to rerun a failed job that we see in 5.4 option

R command in 5.2 will be useful to rerun the application from the failed job...
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2422
Location: Netherlands, Amstelveen

PostPosted: Wed Feb 16, 2011 12:40 am    Post subject:
Reply with quote

What is this? Any job defined in OPC (or TWS) can be rerun. Read the manuals or get a good education.
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2422
Location: Netherlands, Amstelveen

PostPosted: Wed Feb 16, 2011 2:46 pm    Post subject:
Reply with quote

Valdis,

dont pm me please. You could have put your pm here :

The question I asked was In OPC, Is there a way to re run a failed job via a BATCH process?
I now you can re run a job from the ISPF interface but this is not what I want. You can also rerun with an OPC RECOVER statement in the JCL but that only gives you one re run and it's instant.
We have some FTP jobs that ocasionaly fail for conection problems & usually a rerun after 2-3 mins works. So I use an MPF exit to trap the failed job and startr an STC to rerun the job in OPC, but there is NO command to do this This is possible on other scheduling platforms.

My response on your pm :

I guess you use system automation (trapping in MPF) if so, you trigger
a rexx in your message table and issue OPCAMOD, OPCAPOST or INGOPC commands within a timer.
see : OPC Automation Programmers Reference" SC33-7046-03

So everybode on this forum can learn from your questions and the answers you get from me and others.
Back to top
View user's profile Send private message
David Robinson

Active User


Joined: 21 Dec 2011
Posts: 175
Location: UK

PostPosted: Thu Dec 29, 2011 4:21 pm    Post subject:
Reply with quote

This maybe a little late for the OP, but it's really very easy. The OPC RECOVER statement will do exactly what you require.

Firstly, your assertion that the OPC RECOVER statement only gives you one run is not entirely correct. Sure, it will only give you one rerun per RECOVER statement, as obviously you wouldn't want to continuously resubmit a job that was failing. But if you code multiple RECOVER statements, you will get multiple reruns. TWS will comment out one RECOVER statement on each rerun so it is ignored next time.

As for introducing a delay, the easiest way is to use the ADDPROC statement to add a proc containing a delay program in to your JCL. If you don't have a suitable delay program, use the TWS supplied EQQRETWM. You only need to code this on the first RECOVER statement, so the delay proc only gets added once. Alternatively use the ADDAPPL statement to add in a new application that contains a job running on a "wait" work-station which will be a predecessor to your failed job.

And you could if you wanted to rerun the job via your batch started task initiated from the MPF exit triggered by the failure message, but this all seems horribly compliacated.
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 -> IBM Tools All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts FTP - JCL failed while passing FTP co... Suneetha1612 JCL & VSAM 12 Wed Nov 16, 2016 7:33 pm
No new posts ABEND due to FETCH FAILED jackzhang75 ABENDS & Debugging 17 Thu Mar 10, 2016 3:08 am
No new posts Job failed with DJ status code. vaibhavjadhav IMS DB/DC 10 Sat Apr 19, 2014 10:54 pm
No new posts File open failed - contention with b... cser_oxygen CICS 6 Wed Apr 09, 2014 3:20 pm
No new posts NDM - Source file open failed. Errno=... Asif Bhatkar IBM Tools 3 Fri Feb 21, 2014 3:48 pm


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