A situation caused by two or more processes being unable to proceed (and thus release their locks) because they are blocked by locks on resources held by the other process.

learn more… | top users | synonyms

12
votes
1answer
358 views

SQL Deadlock on the same exclusively locked clustered Key (with NHibernate) on delete / insert

I have been working on this deadlock issue for quite a few days now and no matter what I do, it persists in one way or another. First, the general premise: We have Visits with VisitItems in a one to ...
5
votes
1answer
387 views

Deadlock free MERGE-alike in MySQL?

I am trying to implement some parts of MERGE in the MySQL driver in Drupal. Of course, Drupal has something but in truth it only works because the most frequent MERGE issuer just eats exceptions. So, ...
4
votes
1answer
59 views

Why would MySQL request a shared-lock after setting transaction level to READ UNCOMMITTED

Running a processing job in multiple parallel batches which basically reads big chunks of rows to update a few - it's OK here to use a lower transaction level since I know the relevant values won't be ...
2
votes
1answer
218 views

Oracle Ref Partitioning: Deadlock due to child table row migration

My ordering application uses Oracle 11g Database. This DB has a primary table ORDERS and multiple child tables like ORDER_DETAILS, PLAN etc. ORDERS table is LIST partitioned on STATUS column and all ...
2
votes
1answer
103 views

Multi-victim deadlock in SQL Server

I have been seeing a lot of deadlocks occurring on a system with deadlock graphs similar to this one: I have been advised that it is a multi-victim deadlock but I cannot re-create a deadlock graph ...
1
vote
1answer
83 views

How do Locks Work in MySQL or MariaDB

There is a case which makes me a bit confused. As far as I understand deadlocks should appear if there are two query statements (including subqueries) in request (each transaction). So the ordering of ...
1
vote
1answer
48 views

Help understanding InnoDB Deadlock Detection

I have a deadlock occurring when executing an Update and a Select in seperate threads but I'm not sure what can be done about it. Previously my understanding was that this could happen in parallel but ...
1
vote
1answer
174 views

Increased server load after InnoDB deadlock

I am using InnoDB instead of MyISAM for a couple of months right now, and it has really optimized my game database-wise. I was aware of the danger of deadlocks, but hadn't had any problems with it, ...
0
votes
1answer
139 views

SQL Server 2012 - Deadlock happening daily

We have a performance issue with a 3rd-Party application using SQL Server 2012: deadlock happen at least 10 times an hour. The server is virtual server on VMWare 5.5 with PVSCSI adapter in persisted ...
5
votes
0answers
131 views

Complete deadlock on PostgreSQL 9.3 after removing a numeric id

The problem - complete DB lock after a schema change Architecture I use a PostgreSQL 9.3 with PostGIS to store location updates. The updates are written to two tables - location_updates and ...
3
votes
0answers
58 views

MySQL queries waiting for other queries to finish

We have 30-40 different projects in Python and PHP that update, insert and select more than 1 million rows of data in MySQL DB every day. Currently we use InnoDB Engine for our tables. The problem: ...
3
votes
0answers
108 views

Read/Write Deadlock on Ms-Sql Server

We are facing deadlocks when store procedure is concurrently executed. We are using Microsoft SQL Server 2008 R2, concurrent execution is done with java executing multiple request of sp. I have ...
3
votes
0answers
180 views

How to set ALL the replication to DEADLOCK_PRIORITY LOW?

I have just got this email here: Then looking at the sql server log I find this deadlock was caused by one of our procedures (that was the victim) against the replication. O.K. in this case in ...
2
votes
0answers
49 views

Select Query with S lock wins on Insert with IX lock in deadlock

Select Query with S lock wins on Insert with IX lock in deadlock in Sql Server 2008R2. Attaching the deadlock xml file.Please help! http://pastebin.com/nY9EXbS8 This is from the error log by ...
2
votes
0answers
33 views

Index on a highly updated field causing excessive locks in SQL server

I'm in a bit of a conundrum about what the best course of action on this (bad?) index is. I have a table which i use as a notification holder that i watch for database changes with. CREATE TABLE [dbo]...
2
votes
0answers
70 views

SQL Server Check Constraint Lock Order

I'm having problems with SQL Server 2012 filetable. Filetable defines an check constraint on a path_locator field with definition as: /*ParentsAreDirectories*/ (filetable_parents_are_directories((...
2
votes
0answers
83 views

Why is this update creating a deadlock?

I have these queries: (This one was deadlocked) And this one: update tbldealerativacao set flagusado = 0 from tbldealerativacao WITH (NOLOCK) inner join tbldealerusuario WITH (NOLOCK) on ...
2
votes
0answers
158 views

innodb update with limit locks all matching (ignores limit)

For a query similar to this: UPDATE myinnotable1 SET value=5,updated=now(),status=1 WHERE status>10 AND message="match msg" LIMIT 1; I found that innodb engine locks ALL rows matching criteria ...
2
votes
0answers
29 views

Locks while stream reading and deleting/inserting involving the same tables?

I have a question regarding a potential block/lock situation: I am reading data using a select command, which is then modified externally and uploaded to a temporary table. A stored procedure will ...
2
votes
0answers
96 views

Deadlock when CODES table has 41900 rows

I'm having a deadlock accessing the same table from two different jobs. I'm testing it on a SQL SERVER 2012 Enterprise edition. Running SQL Profiler I get this graph: You can find the SQL Server ...
2
votes
0answers
295 views

Read-Commited Snaphsot isolation causing deadlocks?

Our DBA has some type of process setup to monitor deadlocks and sends out an emails when a deadlocks occurs. We have been testing read committed snapshot isolation on our application for a couple ...
2
votes
0answers
4k views

Oracle Select Query Over Database Link Suddenly Hangs Endlessly

I have a query that's been in use for years and today it started hanging endlessly. I took the query apart and found the piece causing it to hang is a simple join on a primary key that should run like ...
2
votes
0answers
427 views

SQL Server 2008 R2 - Deadlock Trace, Need Help Understanding It

I really need help on understanding this deadlock, i've already replaced the values, mind if anyone helps me interpreting where my deadlocks are coming from? What does e_waitpipegetrow mean? btw, i'm ...
1
vote
0answers
57 views

NOLOCK vs Read Uncommitted

in our environment, reports are running on the subscriber and resulting in deadlocks with MS Replication SPs, which are doing inserts/updates. What's the best way to eliminate the deadlocks? We have ...
1
vote
0answers
96 views

How to resolve Innodb lock

I am trying to run a sitemap generator job for Magento and here is what I get as Innodb status after the query has failed to complete even after several hours. I do not know much about DBA stuff and ...
1
vote
0answers
55 views

Is this query actually working?

This is from show engine innodb status ---TRANSACTION 4FF4, ACTIVE 43350 sec, OS thread id 6232 fetching rows mysql tables in use 2, locked 2 480318 lock struct(s), heap size 46578104, 48647170 row ...
1
vote
0answers
61 views

MySQL deadlock in simple table

I'm having a deadlock issue that I don't get. Possibly it's because of the composite index (idSite,timestamp). Maybe it's range locking on it? I have this table: CREATE TABLE `logs` ( `idLog` ...
1
vote
0answers
211 views

MySQL - Preventing lock wait timeout when deleting rows from self

I have a table of around 500k rows (not big data), that I need to query against itself and then delete some of the rows which don't match the filters. At the moment my query looks like this: DELETE ...
1
vote
0answers
84 views

Why does this deadlock occur?

We're using MySQL with the INNODB storage engine. The account table is accessed by two different transactions. We didn't expect a deadlock because only one transaction is holding a lock (2): ---------...
1
vote
0answers
189 views

SQL server deadlock graph explained

I am testing a scenario or recurrent request that ends up in executing the following store procedure simultaneously ALTER PROCEDURE [dbo].[clear_class]( @classID [int]) AS BEGIN DELETE FROM [dbo]....
1
vote
0answers
89 views

InnoDB Deadlocks Involving Currency Transactions

We're dealing with InnoDB deadlocks that are affecting our virtual transaction system. LATEST DETECTED DEADLOCK 150210 20:51:03 *** (1) TRANSACTION: TRANSACTION 0 4240405649, ACTIVE 0 sec, process no ...
1
vote
0answers
1k views

exec sp_getapplock - Different behaviour using go or without go

we have a strange behaviour while using sp_getapplock (we tried to use this to solve a problem with a deadlock involving some insert while another session was trying to execute a ALTER SWITCH command)....
1
vote
0answers
300 views

What do spikes in InnoDB lock structures indicate?

I co-maintain a high traffic site similar to StackExchange. It runs MySQL 5.1 (working on replacing it with MySQL 5.5 or MariaDB). All our tables are InnoDB. MySQL goes down a couple of times a day. ...
1
vote
0answers
757 views

SELECT + INSERT + Query Cache = MySQL lock up

MySQL server seems to constantly lock up and stop responding on certain types of queries and eventually (after couple of minutes of not responding) give up with an error "MySQL server has gone away", ...
1
vote
0answers
248 views

Why Am I Getting Deadlock - Please Read Trace

can anyone help me? i'm getting deadlock on this trace, i'm using symmetricds and i can't understand why i'm getting a deadlock on a certain table. I'm using sql server 2008 r2, ...
0
votes
0answers
29 views

Postgresl database deadlock problem

My Postgresql had following deadlock problem. [2016-06-15 15:38:55.657 MMT] ERROR: deadlock detected [2016-06-15 15:38:55.657 MMT] DETAIL: Process 2488 waits for ShareLock on transaction 1050868701;...
0
votes
0answers
37 views

Deadlocking on two update statements

Server Info: Microsoft SQL Server 2005 - 9.00.5057.00 (X64) Standard Edition (Build 7601: Service Pack 1) I have a table called LAB it has about 38 million rows in it. The primary key is a single ...
0
votes
0answers
34 views

Database tempdb deadlock

I have been getting a deadlock error for a long time : Could somebody please help me as to what kind of deadlock this is and how to resolve the same. Please ask for any additional details if needed....
0
votes
0answers
59 views

database Deadlock again

Once again I have a deadlock problem with the following log: [17/03/16 16:42:20.020 -0300] FATAL OPERACIONES: SQLException: CreateEquipo: ERROR: deadlock detected Detail: Process 2923 waits for ...
0
votes
0answers
28 views

Resetting deadlock count statistics

It seems that just restarting the PostgreSQL service doesn't clear / reset the detected deadlock count. How can it be restarted to zero? select version(); PostgreSQL 9.4.5 on x86_64-unknown-linux-gnu,...
0
votes
0answers
90 views

How can I avoid this deadlock in MariaDB?

I saw that I got a deadlock in a MariaDB cluster. I have 3 cluster database. What should I do to avoid that? 160211 16:29:02 *** (1) TRANSACTION: TRANSACTION 75AB6B17, ACTIVE 0 sec starting index ...
0
votes
0answers
66 views

mariadb error transaction deadlock

I use galera cluster with 4 nodes, mariadb, we insert nearly 12million data. Insert task was finished. However we have lost 11000 data. I don't know where they go. In error log it writes; 151220 17:...
0
votes
0answers
35 views

How system resolves when particular resource lock at uncommitted transaction

Let us assume Transaction T1#: Initiated on 2015-10-30 10:25:41.380 Transaction T2#: Initiated on 2015-10-30 10:25:41.580 The above two transactions are initiated through application. T1# & ...
0
votes
0answers
91 views

How to avoid deadlocks when running queries on a remote server

I need to pull data from many different systems, all on remote, LIVE SQL Servers into one place for a one-off piece of work that will last a few weeks. This has to be run multiple times during the ...
0
votes
0answers
56 views

mysql deadlock issues

we are having starnge deadlock issue. We have a deadlock in mysql and it appears conitously when we run engine innodb command. the webserver it is comming from do not exist as we have manually killed ...
0
votes
0answers
323 views

Deadlocks due to foreign keys (MySQL)

We are in the process of creating a web application using mysql as a data source. We are using spring with hibernate as an ORM framework. We have hundreds of entities with relations (manyToMany \ ...
0
votes
0answers
124 views

InnoDB says I'm in Deadlock when it should not be

I'll do my best to explain the situation. I'm at a complete loss. Preliminaries I'm running a Java Web Application in Tomcat 7.0 using a JDBC Connector to communicate with my MySQL Database. The ...
0
votes
0answers
61 views

Is it possible for a SELECT-only stored procedure to deadlock on itself?

Environment is Microsoft SQL Server 2012. Is it possible for a stored procedure consisting exclusively of SELECT statements to deadlock on itself? That is the report I am getting from a vendor for ...
0
votes
0answers
613 views

Single DELETE statement deadlocking in Sybase ASE

I've got a fairly straightforward process running on ASE 15.7, that creates rows in two tables and later deletes them. The tables are both configured to use datapages for the locking scheme, and the ...
0
votes
0answers
179 views

Lock timeouts on a table with two keys, where only one connection writes for a given value of the first key at a time

I have a table user_rollup_message_list that is keyed by (user_id, message_reference). It is a write-heavy table, and gets enough writes that I get many lock timeouts, with a timeout of 50 seconds, ...