• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 3491
  • Last Modified:

MYSQL error: Deadlock found when trying to get lock; try restarting transaction. What does this mean?

MySQL Error - 1213 Deadlock found when trying to get lock; try restarting transaction
DELETE FROM upsl WHERE ipaddress = '100.x.x.x'

I saw this error this morning, I have no idea what it means. Upsl is a innodb table, with lotsa updates. Anyone have an idea?

Thanks
0
Octalys
Asked:
Octalys
  • 2
  • 2
1 Solution
 
UmeshCommented:
Below link may explain you very clearly about the error..

http://dev.mysql.com/doc/refman/5.0/en/innodb-lock-modes.html

BTW, Whats your tx_isolation?

Please gimme the output of

SELECT @@global.tx_isolation;
SELECT @@tx_isolation;


0
 
OctalysAuthor Commented:
@@global.tx_isolation  
REPEATABLE-READ

@@tx_isolation  
REPEATABLE-READ

Hi,

Thanks for the link. I am reading it now
0
 
OctalysAuthor Commented:
I still dont fully understand it. Been using MySQL over 5 years, I never had any locking problem. And I am doing pretty simple things with this table.

Update, Update, Update etc etc, Sleep 1 second then Delete row.
0
 
UmeshCommented:
Which versions you were using earlier? which engines your were using?

Can you post the output of below commands

show global status;
show global variables;
0

Featured Post

Fill in the form and get your FREE NFR key NOW!

Veeam is happy to provide a FREE NFR server license to certified engineers, trainers, and bloggers.  It allows for the non‑production use of Veeam Agent for Microsoft Windows. This license is valid for five workstations and two servers.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now