If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > cannot DROP INDEX, lock timeout

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 08-23-11, 16:28
ACheeseman1 ACheeseman1 is offline
Registered User
 
Join Date: Aug 2011
Posts: 3
cannot DROP INDEX, lock timeout

i created an index in the wrong schema and i need to move it to the correct schema but i cannot drop the index, it keeps returning a lock timeout error

help?

Quote:
[IBM][CLI Driver][DB2/NT64] SQL0911N The current transaction has
been rolled back because of a deadlock or timeout. Reason code
"68". SQLSTATE=40001



Explanation:

The current unit of work was involved in an unresolved contention for
use of an object and had to be rolled back.

The reason codes are as follows:

2

The transaction was rolled back due to a deadlock.


68

The transaction was rolled back due to a lock timeout.


72

The transaction was rolled back due to a DB2 Data Links Manager
error during the transaction.


73

The transaction was rolled back because a queuing threshold
such as the CONCURRENTDBCOORDACTIVITIES threshold caused two or
more activities to reach a deadlock state. For more
information, see "CONCURRENTDBCOORDACTIVITIES threshold" in the
DB2 Information Center.

The application was rolled back to the previous COMMIT.

User response:

The changes associated with the unit of work must be entered again.

To help avoid deadlock or lock timeout, issue frequent COMMIT
operations, if possible, for a long-running application, or for an
application likely to encounter a deadlock.

Federated system users: the deadlock can occur at the federated server
or at the data source. There is no mechanism to detect deadlocks that
span data sources and potentially the federated system. It is possible
to identify the data source failing the request (refer to the problem
determination guide to determine which data source is failing to process
the SQL statement).

Deadlocks are often normal or expected while processing certain
combinations of SQL statements. It is recommended that you design
applications to avoid deadlocks to the extent possible.

For more detailed information about preventing deadlocks or lock
timeouts search the DB2 Information Center
(DB2 Database for Linux, UNIX, and Windows) using phrases such
as "deadlock prevention", and terms such as "deadlocks" and "lock
timeouts".

If a deadlock state was reached because of a queuing threshold such as
the CONCURRENTDBCOORDACTIVITIES threshod, increase the value of the
queuing threshold.

sqlcode: -911

sqlstate: 40001
Reply With Quote
  #2 (permalink)  
Old 08-23-11, 16:43
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
It might be used by running applications. Wait until they disconnect.
Reply With Quote
  #3 (permalink)  
Old 08-23-11, 16:45
ACheeseman1 ACheeseman1 is offline
Registered User
 
Join Date: Aug 2011
Posts: 3
oh, okay.
guess i am not used to indexes being lockable
Reply With Quote
  #4 (permalink)  
Old 08-23-11, 17:07
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
Quote:
Originally Posted by ACheeseman1 View Post
guess i am not used to indexes being lockable
What are you used to? Dropping an index while it is being scanned by an application? What would be the expected application behaviour in that case?
Reply With Quote
  #5 (permalink)  
Old 08-23-11, 17:11
ACheeseman1 ACheeseman1 is offline
Registered User
 
Join Date: Aug 2011
Posts: 3
point made
Reply With Quote
  #6 (permalink)  
Old 08-23-11, 17:27
db2girl db2girl is offline
∞∞∞∞∞∞
 
Join Date: Aug 2008
Location: Toronto, Canada
Posts: 1,816
Quote:
Originally Posted by n_i View Post
What are you used to?
I'm getting used to feeling earthquakes
Reply With Quote
  #7 (permalink)  
Old 08-23-11, 17:46
n_i n_i is offline
:-)
 
Join Date: Jun 2003
Location: Toronto, Canada
Posts: 4,449
Someone tried to drop a really large index, I s'pose.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On