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
 

 

Dead lock in DB2 - CICS programs

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CICS
View previous topic :: :: View next topic  
Author Message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1529
Location: Andromeda Galaxy

PostPosted: Fri Sep 13, 2013 3:47 pm    Post subject: Dead lock in DB2 - CICS programs
Reply with quote

Hi,

I have a transaction id TST1 which calls program A and Program A is main module which connects between Java and Mainframe.

Program A in turn links 30 different CICS modules

Now I have a situation where DB2MSTR shows up something like

CORRELATION-ID=ENTRTST10005 deadlocked with
CORRELATION-ID=ENTRTST10025

Does the last 4 digit number in Correlation id has any significant meaning ?

How can we figure out which 2 programs were contending for resource?

Note : I felt this query is closely related to CICS so posted here
Back to top
View user's profile Send private message

dick scherrer

Site Director


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

PostPosted: Fri Sep 13, 2013 7:17 pm    Post subject:
Reply with quote

Hello,

Your situation is caused by a design problem using DB2. While this is run in CICS, it it a DB2 situation that needs corrected (i believe).

As with any deadlock, multiple processes are trying to "lock" the same data but not in the same order.

When i looked in the db2 doc just now, CORRELATION-ID is involved with MQ.
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1529
Location: Andromeda Galaxy

PostPosted: Fri Sep 13, 2013 7:22 pm    Post subject:
Reply with quote

Hi Dick,

Thanks for the response but here this program is not involved with MQ

So will increasing the LOCKMAX number of Table space help to reduce the deadlocks ?
Back to top
View user's profile Send private message
dick scherrer

Site Director


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

PostPosted: Fri Sep 13, 2013 7:26 pm    Post subject:
Reply with quote

Hi PB,

No, i don't think so. It only takes 2 tasks to generate a deadlock situation. Upping the number of possible locks would most likely not help this deadlock.

About MQ - i too was surprised to see those entries in the DB2 manual . . . icon_confused.gif
Back to top
View user's profile Send private message
Jose Mateo

Active User


Joined: 29 Oct 2010
Posts: 110
Location: Puerto Rico

PostPosted: Fri Sep 13, 2013 10:20 pm    Post subject: Reply to: Dead lock in DB2 - CICS programs
Reply with quote

Good afternoon, Pandora!

Have you scanned the MVS log for more information on this problem?
Back to top
View user's profile Send private message
agkshirsagar

Active Member


Joined: 27 Feb 2007
Posts: 685
Location: Earth

PostPosted: Sat Sep 14, 2013 12:23 am    Post subject:
Reply with quote

Please check this link to find more information on this topic.
As far as your first question goes, the number is to uniqely identify the threads. Looks like the correlations are two instances of transaction TST1.
Back to top
View user's profile Send private message
colin777

New User


Joined: 06 Jun 2013
Posts: 19
Location: Singapore

PostPosted: Mon Sep 16, 2013 1:10 pm    Post subject:
Reply with quote

Hi,

These Correlation Ids :

CORRELATION-ID=ENTRTST10005 deadlocked with
CORRELATION-ID=ENTRTST10025

are first 4 chars is the type of Thread, ENTR is Entry Thread. Then next 4 chars is the Transid, then followed by task number of the task.

But please note, this is only valid for knowing the Transid/Task number, if this transaction did the signon to DB2, meaning if the Thread was reused it would be the Transaction Id, that used the thread first, that did the signon. Only the Attachment Facility can change the Correlation Id, by another Transaction issuing signon.

HTH

Colin777
Back to top
View user's profile Send private message
Pandora-Box

Moderator


Joined: 07 Sep 2006
Posts: 1529
Location: Andromeda Galaxy

PostPosted: Wed Sep 18, 2013 8:28 pm    Post subject:
Reply with quote

Thanks all for your replies

As of now we have increased the LOCKMAX and this has almost eliminated the deadlocks for past few days
Back to top
View user's profile Send private message
dick scherrer

Site Director


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

PostPosted: Wed Sep 18, 2013 8:58 pm    Post subject:
Reply with quote

Hello,

Good to hear this helped, but i believe the process(es) need to be revised to eliminate the deadlocks. . .
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 -> CICS All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts CICS START AND CANCEL blayek CICS 1 Wed Dec 07, 2016 3:27 am
No new posts How does a called pgm know if its cal... Graeme Westerman COBOL Programming 4 Tue Nov 29, 2016 9:25 pm
No new posts CICS Roll back partially - Need to re... dwijadas CICS 4 Wed Nov 16, 2016 4:30 pm
No new posts CICS NEW SIT PARAMETERS CICS BEHAVIOR... Kyle Carroll CICS 0 Fri Nov 04, 2016 11:55 pm
No new posts Cobol list of programs being called biswajit.dattagupta COBOL Programming 5 Tue Nov 01, 2016 2:10 am


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