ORA-00060: deadlock detected

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
dorescan
Premium Member
Premium Member
Posts: 10
Joined: Wed Nov 10, 2004 5:15 am
Contact:

ORA-00060: deadlock detected

Post by dorescan »

Hi guys,

today in the middle in the project our DS Parallel jobs started to crash with this message:

CUS_CUST_CONTRACTS,1: Open failed for update.
Update is: ... (Some simple SQL)
sqlcode is: -60
esql complaint: ORA-00060: deadlock detected while waiting for resource


It happens with all Orchestrate processes.

We have tried to turn on deadlock manager, but with no help.

We have not change any parameters in either Database (10g) or DataStage. Yesterday everything was fine!

Please help....

Drazen
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

This is an Oracle error, not a DataStage error.

Something in your design, or something else that is running on Oracle at the same as your DataStage job, is causing a deadlock situation. For example, are you trying to update the same table that you're selecting rows from?
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
dorescan
Premium Member
Premium Member
Posts: 10
Joined: Wed Nov 10, 2004 5:15 am
Contact:

Post by dorescan »

Hi, we have created bitmap indexes on few tables yesterday afternoon. After we have dropped those indexes and recreated them as ordinary non-unique indexes, it works fine. I suppose that was creating a problem, but we should find some workaround. Does anybody use parallel upserts in the table with bitmap indexes enabled?

Thanks,

Drazen
mouthou
Participant
Posts: 208
Joined: Sun Jul 04, 2004 11:57 pm

Post by mouthou »

It is a problem with the way datastage handles the parallelism. try increasing the MAXTRANS database parameter for the table and the index on that table.

But if you dont want parallesim, include the $APT_CONFIG file parameter in the job and modify it for single node file. It should run fine.............

Thanks.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Bitmap Indexes are not something you want to be updating, if you can help it. Found this quote at a site I have bookmarked:
You must also be concerned about high-volume updates. Bitmap indexes are notoriously slow to change when the table data changes, and this can severely slow down INSERT and UPDATE DML against the target tables.
We drop and rebuild the few that we have at each end of the processing cycle.
-craig

"You can never have too many knives" -- Logan Nine Fingers
vinaymanchinila
Premium Member
Premium Member
Posts: 353
Joined: Wed Apr 06, 2005 8:45 am

Post by vinaymanchinila »

I agree with "mouthou", it looks like a DS bug, even though I have the insert array soze as 1 instead of the default 500, my job aborts with the "ORA-00060: deadlock detected while waiting for resource" and my DBA is sure there are no locks .
Jay
Participant
Posts: 105
Joined: Tue Nov 11, 2003 8:28 pm

Post by Jay »

I think what Ray is telling is true. I had a similar problem in one of my jobs. I discussed the deadlock issue with my DBA and team members. We found that i was updating the same row in parallel processes. Once for Insert and once for Update. I think i had selected the Insert and Update option. This was creating the deadlock.

So i created constraints in the transformer and explicitly asked the job to Insert or Update.

thanks
jay
vinaymanchinila
Premium Member
Premium Member
Posts: 353
Joined: Wed Apr 06, 2005 8:45 am

Post by vinaymanchinila »

Can you eloborate on
"So i created constraints in the transformer and explicitly asked the job to Insert or Update. "
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Something like this; the Lookup determines whether the row (key) already exists in the table (possibly against a key-only Data Set) and, on that basis, either sends the row to be inserted (insert only) or to be updated (update only).

Code: Select all

   -----> Lookup  -----> Insert
                  -----> Update
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
vinaymanchinila
Premium Member
Premium Member
Posts: 353
Joined: Wed Apr 06, 2005 8:45 am

Post by vinaymanchinila »

Thats a round about way of doing it, I had this situation before and it worked when I reset the array size to 1, have raised a case with IBM will post the solution if they come up with one, else will have to go the constraints way.

Thanks and Ray do you happen to know of the reviews on advanced EE training from IBM?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

vinaymanchinila wrote:Ray do you happen to know of the reviews on advanced EE training from IBM?
Student feedback forms are returned to IBM. After that they are analyzed to look for ways to improve the classes. The instructor quickly looks at them (maybe) at the end of class, and never sees them again. If there are issues that IBM has with the instructor, presumably IBM gets in touch with the instructor. Never happened to me, though, so I can't be sure on that one. I guess the fact that I get repeat business is some form of feedback.

Is that what you meant?
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Madhav_M
Participant
Posts: 43
Joined: Sat Jul 10, 2004 5:47 am

Post by Madhav_M »

Hi,
I am also facing the same issue! MAXTRANS value for the table to be updated set to 255. APT_CONFIG_FILE is set to 1way.apt.

After the above settings, job started updating around 100K records however 200K records are getting rejected!!

Any thoughts?

Thanks
Madhav
Post Reply