IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Issue with job submited using INTRDR..


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
sejal214

New User


Joined: 08 Nov 2006
Posts: 5

PostPosted: Sun Aug 07, 2011 6:41 pm
Reply with quote

Hi!
In my application, main job A submits the job B (which sends email to user) in case there is an abend to the program executed by job A.

Actually job B gets submitted and held. Later Proc A gets executed. Inside PROC A, there is a step which cancels the job B in case everything is fine and no abend.
Now the issue is even in case of no ABEND job B gets executed and hence unnecessary emails are going.
I tried changing the job name for JOB B, it worked fine (successfully cancelled). Then i tried abending the prog A (from proc A) manually. this also worked fine and JOB B got executed. Again when there was no abend, still JOB B got executed..

In the Spool display of JOB A, i can see the message that JOB B got cancelled but it does not get cancelled actually.

Kindly let me know the solution for this problem. is there anything to do with DEVE environment?
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Sun Aug 07, 2011 7:17 pm
Reply with quote

Instead of trying to cobble together something together, doing this, and that until it works, why not investigate the possibilities with your scheduler? Job fails, do this, job completes, do that, job ends with rc ne 0, do the other?
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10872
Location: italy

PostPosted: Sun Aug 07, 2011 7:49 pm
Reply with quote

the whole setup is clear as mud...
who is going to release job B in case of <abend> of job A ?

why not use Your scheduler facilities

the topic almost fall under the wrath of what you deserve if You try to write Your own job scheduler
www.ibmmainframes.com/viewtopic.php?t=20820&highlight=

unless the TS clarify the topic will be locked and moved
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Mon Aug 08, 2011 2:41 am
Reply with quote

Hello and welcome to the forum,

Before implementing something convoluted like this, it would have been better to talk with your scheduling, operations, or seniors to learn what is already available on your system.

This needs to be set aside and something usng the scheduling or automation software should be considered.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Mon Aug 08, 2011 4:30 am
Reply with quote

Hi,

as an aside from using the scheduling or automation software, why not submit job B only when there is an abend in job A and remove the TYPRUN=HOLD.


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

Senior Member


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

PostPosted: Mon Aug 08, 2011 6:20 am
Reply with quote

Why not send the e-mail from job A using COND?
Back to top
View user's profile Send private message
sejal214

New User


Joined: 08 Nov 2006
Posts: 5

PostPosted: Mon Aug 08, 2011 12:58 pm
Reply with quote

Thank you all for the reply!

The system is very OLD and i can not make any major changes as of now. I have to find out the reason and solution for the problem.

JOB A
Step1 - copy the JOB B to INTRDR
Step2 - Execute PROC A


PROC A
step1 - Execute prog A
Step2 - cancel Job B if everything is fine. (using COND)

I dont understand inspite of the message in JESMSGLG for JOB A as
JOB47174 +A --> B CANCELLED
the jobB is not getting cancelled and getting executed.

/BR
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Mon Aug 08, 2011 1:26 pm
Reply with quote

With respect, chopping out some old JCL is not the same as digging into a 15-year-old DB update program written by a "programmer" with a heightened sense of the bizarre.

If you want to hunt it down, try google. Try the manuals (look up the Canceled message) look specifically at all references to the internal reader, as you could find a clue anywhere. Try collleagues, support personnel, sysprogs, etc.

I don't know the answer myself. Are the job numbers the same?
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


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

PostPosted: Mon Aug 08, 2011 1:53 pm
Reply with quote

Quote:

I dont understand inspite of the message in JESMSGLG for JOB A as
JOB47174 +A --> B CANCELLED
the jobB is not getting cancelled and getting executed.


That is not JES output, if you want help give the real world JES
output not some edited line.
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Mon Aug 08, 2011 3:12 pm
Reply with quote

sejal214 wrote:
[...]

JOB A
Step1 - copy the JOB B to INTRDR
Step2 - Execute PROC A


PROC A
step1 - Execute prog A
Step2 - cancel Job B if everything is fine. (using COND)

I dont understand inspite of the message in JESMSGLG for JOB A as
JOB47174 +A --> B CANCELLED
the jobB is not getting cancelled and getting executed.

[...]


Can you post the messages from the job doing the cancel, and the same Job B succeeding?

Why you'd not want to use the scheduler I don't know, but if you delete Step1 of Job A and change Step2 of Proc A to do the work of Job B (using COND), won't you get what you want (as has previously been suggested)?

I don't like the idea of you issuing cancel commands. Can you do other "serious" jes commands?

What could happen if a previously gruntled employee with access to the prod JCL became disgruntled? Literally Bedlam. What about the fraudster who cancels the job sending the e-mails unconditionally. I, and Auditors I know, are somewhat concerned at this.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Mon Aug 08, 2011 5:52 pm
Reply with quote

You could have the problem of 2 jobs on the queues with the sam jobname - then JES does not know which job to cancel.
Back to top
View user's profile Send private message
Ed Goodman

Active Member


Joined: 08 Jun 2011
Posts: 556
Location: USA

PostPosted: Mon Aug 08, 2011 7:33 pm
Reply with quote

Any chance the format of the cancel command is now different? Like, did you just upgrade your OS or the version of JES? Or maybe even switch spool programs?

The old job is probably still sending its cancel command as appropriate, but it's now using the wrong format.

Try canceling a job by hand. What command did you use? Is the same one the old job is using?
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts Issue after ISPF copy to Linklist Lib... TSO/ISPF 1
No new posts Facing ABM3 issue! CICS 3
No new posts Panvalet - 9 Character name - Issue c... CA Products 6
No new posts Issue with EXEC CICS QUERY SECURITY c... CICS 6
Search our Forums:

Back to Top