how to remove locks in db2 version 9.7
Locking in db2
Collapse
X
-
Tags: None
-
-
Lock
My db is not working due to lock, one of the table has many lock. I have already take the snaphot for "LOCKS" at the time of locking & force the same.
But i want to know the exact procedue to avoid the lock in application.Comment
-
I'm sure you don't want to make your application behave incorrectly -you don't want to release being held by an application.
I believe you need to find a way to make your queries perform better; check the query plans to make sure you have proper indeces. May be you need to increase the max_locks and (change lock_timeout to something like 120). You need to make sure your queries run the correct isolation level. If you have a database migrated from earlier release, make sure you have Currently committed option enabled -it's not enabled by default on migrated databases.Comment
-
Hi,
Set the lock timeout dbcfg param as 60 or more depending on the application setup and setup a deadlock monitor as well.
You can also want to set curr_commit value to help you in unnecessary locking.
Also in V9.7 memory for locking requirements has been increased so you should increase the locklist and maxlock to allow more memory for the locks in V9.7.
Cheers, VijayComment
Comment