Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I sometimes get this while running a drush command.
my innodb wait timeout is set high at 150 so I dont think that's the error.
PDOException: SQLSTATE[HY000]: General error: 1205 Lock wait timeout exceeded; try restarting transaction: SELECT 1 AS expression
FROM
{variable} variable
WHERE ( (name = :db_condition_placeholder_0) ) FOR UPDATE; Array
(
[:db_condition_placeholder_0] => cache_flush_cache_views
)
in MemCacheDrupal->variable_set() (line 397 of modules/all/memcache/memcache.inc).
Comments
Comment #1
marcingy CreditAttribution: marcingy commentedThis is not a bug with memcache module, this module is just where it shows up. Basically you have a slow running transaction.
Comment #2
lotyrin CreditAttribution: lotyrin commentedAre you using elysia cron? #2013138: Full Table Locks on Variable tables causes site short site outage may be related.
Comment #3
lotyrin CreditAttribution: lotyrin commentedNevermind, that seems like it should only affect Drupal 6.
Comment #4
davidwbarratt CreditAttribution: davidwbarratt commentedAny way to reproduce this error consistantly?
Comment #5
ann b CreditAttribution: ann b commentedOne of our users ran into this problem yesterday trying to update a blog post node.
PDOException: SQLSTATE[HY000]: General error: 1205 Lock wait timeout exceeded; try restarting transaction: UPDATE {node} SET vid=:db_update_placeholder_0, type=:db_update_placeholder_1, language=:db_update_placeholder_2, title=:db_update_placeholder_3, uid=:db_update_placeholder_4, status=:db_update_placeholder_5, created=:db_update_placeholder_6, changed=:db_update_placeholder_7, comment=:db_update_placeholder_8, promote=:db_update_placeholder_9, sticky=:db_update_placeholder_10, tnid=:db_update_placeholder_11, translate=:db_update_placeholder_12 WHERE (nid = :db_condition_placeholder_0) ; Array (...) in drupal_write_record() (line 7202 of <drupal_root>/includes/common.inc).
Drupal 7.32
PHP 5.4.4-14+deb7u11
MySQL 5.5.37-0+wheezy1
I had updated the blog post, saved and logged out. Then about 30 minutes later, the user attempted to update the blog post when this error occurred.
Comment #6
kenorb CreditAttribution: kenorb commentedComment #7
Minaxi1g CreditAttribution: Minaxi1g commentedam too getting this error however for admin only. Error is below mentioned:
PDOException: SQLSTATE[HY000]: General error: 1205 Lock wait timeout exceeded; try restarting transaction: SELECT revision.order_number AS order_number, revision.revision_id AS revision_id, revision.revision_uid AS revision_uid, revision.mail AS mail, revision.status AS status, revision.log AS log, revision.revision_timestamp AS revision_timestamp, revision.revision_hostname AS revision_hostname, revision.data AS data, base.order_id AS order_id, base.type AS type, base.uid AS uid, base.created AS created, base.changed AS changed, base.hostname AS hostname FROM {commerce_order} base INNER JOIN {commerce_order_revision} revision ON revision.revision_id = base.revision_id WHERE (base.order_id IN (:db_condition_placeholder_0)) FOR UPDATE; Array ( [:db_condition_placeholder_0] => 4571 ) in DrupalDefaultEntityController->load() (line 191 of /home4/goclubvo/public_html/aqueousvapor/includes/entity.inc).
Any way to reproduce this error consistantly?
Comment #8
kenorb CreditAttribution: kenorb commented