Title: Delete transient &#8211; WordPress database error Deadlock
Last modified: September 1, 2016

---

# Delete transient – WordPress database error Deadlock

 *  Resolved [magicwizardy](https://wordpress.org/support/users/magicwizardy/)
 * (@magicwizardy)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/delete-transient-wordpress-database-error-deadlock/)
 * Hi,
 * Recently our site has been throwing a constant error (every ~3 seconds) about
   MYSQL Deadlock… Our logs show that it is a new error:
 * `WordPress database error Deadlock found when trying to get lock; try restarting
   transaction for query DELETE FROM wp_options WHERE option_name LIKE '\\\\_transient\\\\_%
   1466643601' ORDER BY option_id LIMIT 1000; made by require('wp-blog-header.php'),
   wp, WP->main, WP->parse_request, do_action_ref_array, call_user_func_array, WC_API-
   >handle_rest_api_requests, WC_API->handle_v2_rest_api_request, WC_API_Server-
   >serve_request, WC_API_Server->dispatch, call_user_func_array, WC_API_Products-
   >edit_product, wp_update_post, wp_insert_post, wp_transition_post_status, do_action('
   transition_post_status'), call_user_func_array, WC_Post_Data::transition_post_status,
   WC_Post_Data::delete_product_query_transients, WC_Cache_Helper::get_transient_version,
   WC_Cache_Helper::delete_version_transients`
 * The function `delete_version_transients` located in `web/app/plugins/woocommerce/
   includes/class-wc-cache-helper.php:110` seems to be the problem – or at least
   part of it.
 * The only update we made – and could be relevant with this error’s timeline – 
   is installing the `woocommerce-direct-checkout` plugin
 * Could you shed some light and help me fix it, please? It is bringing down our
   site constantly.
 * Thank you
 * Woocommerce -> Version 2.4.13
    WooCommerce Direct Checkout -> Version 1.1.2 W3
   Total Cache -> 0.9.4.1
 * [https://wordpress.org/plugins/woocommerce/](https://wordpress.org/plugins/woocommerce/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Contributor [Mike Jolley](https://wordpress.org/support/users/mikejolley/)
 * (@mikejolley)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/delete-transient-wordpress-database-error-deadlock/#post-7508611)
 * Does direct checkout when disabled remove the error? I wonder if you have something
   trying to flush transients during order creation (which uses a MySQL transaction).
 *  [Krzysztof Dryja (Aspexi)](https://wordpress.org/support/users/cih997/)
 * (@cih997)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/delete-transient-wordpress-database-error-deadlock/#post-7508770)
 * Same issue here.
 * Is there anything we can do with the WooCommerce code to debug / fix this?
 *  Plugin Contributor [Mike Jolley](https://wordpress.org/support/users/mikejolley/)
 * (@mikejolley)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/delete-transient-wordpress-database-error-deadlock/#post-7508771)
 * See my comment above – you need to narrow down the cause for us.
 *  [Krzysztof Dryja (Aspexi)](https://wordpress.org/support/users/cih997/)
 * (@cih997)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/delete-transient-wordpress-database-error-deadlock/#post-7508773)
 * Thanks Mike.
 * Some kind of workaround for me was enabling W3 Total Cache -> Object Cache. No
   deadlocks so far.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Delete transient – WordPress database error Deadlock’ is closed to new
replies.

 * ![](https://ps.w.org/woocommerce/assets/icon.svg?rev=3234504)
 * [WooCommerce](https://wordpress.org/plugins/woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce/reviews/)

## Tags

 * [deadlock](https://wordpress.org/support/topic-tag/deadlock/)
 * [MySQL](https://wordpress.org/support/topic-tag/mysql/)

 * 4 replies
 * 3 participants
 * Last reply from: [Krzysztof Dryja (Aspexi)](https://wordpress.org/support/users/cih997/)
 * Last activity: [9 years, 10 months ago](https://wordpress.org/support/topic/delete-transient-wordpress-database-error-deadlock/#post-7508773)
 * Status: resolved