Deadlock error - 05-08-2006 , 12:22 AM
I am working with an application with a high rate of
inserts/updates/deletes into a particular table, and recently am
getting the following error code. My table uses InnoDB engine.
ERROR 1213 (40001): Deadlock found when trying to get lock; try
I read the section of MySQL documentation relating to this error and
deadlock detection in particular, but it does not appear to address my
(a) Can an INSERT throw this error? Or is it applicable only to UPDATEs
and DELETEs (something about INSERT only locking the row inserted).
(b) Is there any configuration setting that can be tuned to reduce the
chances of this happening? I know I could just retry the transaction,
but the application is pretty realtime and most times these database
calls are fire-and-forget.