• Hi,
    I have been trying to update WooCommerce for few weeks now. Everything goes fine until it’s time to update the database. It doesn’t do it automatically so I’ve been manually clicking them. I have read that some people have experienced similar issues.

    But for me the biggest issue is that after manually clicking “run” on the “on sale” update command (can’t remember exactly the name of command) the site won’t load and gives “504 Gateway Time-out”. Yesterday I decided to wait until today and the site had recovered. But the update was still in process and showed at pending also. So when I clicked again “run” it did the same. And it recovered wuite fast. Until the site started giving the 504 again.

    I’m running the update on staging site but I would like to get this update done. How can I do that?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Petri Lautam?ki

    (@rinssi)

    So the site started working again.

    Hook: wc_update_product_lookup_tables_column
    Status: In-progress
    Argument: ‘column’ => ‘onsale’
    Group: wc_update_product_lookup_tables
    Recurrence: Non-repeating
    Scheduled Date: 2020-01-02 10:43:51 +0000 (1 day 2 hours ago)
    Log: 2020-01-02 10:43:43 +0000
    action created
    2020-01-02 10:56:05 +0000
    action started

    There is also another one of those in “in-progress” from today. As well as “‘update_callback’ => ‘wc_update_340_state'”.

    AJ a11n

    (@amandasjackson)

    Hi @rinssi

    We saw similar behavior on a few sites a while back, when the update scripts for WooCommerce 3.6. didn’t set up all the required database tables. There was a fix included for this problem in WooCommerce version 3.6.3 and newer.

    Once a site is updated to version 3.6.3 or newer, you need to fix the database rows that were affected. To do this, you can go to WooCommerce > Status > Tools and regenerate product lookup tables on that page:


    Link to image: https://d.pr/i/PQiztW

    It may take up to 10-15 minutes to complete, depending how many products there are in your store.

    This won’t however execute these scripts immediately but rather add them again to the Action Scheduler queue. This means that if there’s a wider problem with Action Scheduler or Cron in general, they might again get stuck there forever.

    Because you’re seeing there some events that were scheduled more than 20 minutes ago, this means something has likely gone wrong with WP Cron:

    To verify this you can install a plugin called WP Crontrol and go to Tools > Cron Events in WP Admin. If there are any problems processing the queue, there will be an error message at the top of this page. This will help you find whether there’s an error triggered somewhere, Cron is disabled, or there’s some server problem.

    In most cases, your website hosting company should be able to help solve problems with cron.

    We haven’t heard back from you in a while, so I’m going to mark this as resolved – if you have any further questions, you can start a new thread.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘WooCommerce database update crashes site’ is closed to new replies.