3

Magento showing error Order saving error: SQLSTATE[HY000]: General error: 1205 Lock wait timeout exceeded; try restarting transaction, on placing order at backend. Still Order has been saved with status "pending" and then if I generate invoice, this does not show MRP in invoice PDF.

So I need to cancel this order and have to reorder this, this time there no error appears.

I am not aware about this what is happening there and its cause.

can anyone help to to resolve this problem

marked as duplicate by Rakesh Jesadiya, Fabian Schmengler, Keyul Shah, Amit Bera, brentwpeterson Sep 22 '16 at 21:22

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

1

This error means that the table is locked by another process. In MySQL database when a process is launched on table, it lock the table to avoid another process to messed up with the first one (like cron in Magento)
You can increase the variable innodb_lock_wait_timeout to avoid this error but take care this could be the result of an another process.
For example if you have a cron that make action on this table and run for a long time, this could lock the table and generate this error when another process try to access the table.
In short try to look if you have a process that make actions in your database in the same time and increase the innodb_lock_wait_timeout variable.


Source / help
- https://dev.mysql.com/doc/innodb/1.1/en/innodb-other-changes-innodb_lock_wait_timeout.html
- https://dba.stackexchange.com/a/101000

Not the answer you're looking for? Browse other questions tagged or ask your own question.