• Resolved ghassenpflug

    (@ghassenpflug)


    Hi, finally got a bug report working on my staging site.

    I run WP 5.4.1, Yoast SEO 13.5 (free version) on Debian unstable with MariaDB 10.3.22 and PHP 7.3.15.
    My wp-config.php file has the following for charset and collation:

    define('DB_CHARSET', 'utf8');
    define('DB_COLLATE', '');

    Behaviour:

    1. The update of the Yoast plugin from the dashboard “Plugins” screen completes successfully, no debug.log generated.

    2. Then, when I click on dashboard “Updates” again to check if anything else needed, then I get the dreaded “Yoast SEO was unable to create the database tables required and as such will not function correctly.” message, and a debug log is generated, as below.

    It looks like a spurious error message since the table already exists. I have seen you want to do a re-index on sites in 14.0.4. Would it be useful to delete the table first then, or copy it somewhere else, e.g., for downgrade purposes, and then go ahead with 14.0.4 required table generation?

    [03-May-2020 05:08:41 UTC] WordPress database error Table ‘wpstg0_yoast_indexable’ already exists for query CREATE TABLE wpstg0_yoast_indexable (
    id int(11) UNSIGNED auto_increment NOT NULL,
    permalink mediumtext,
    permalink_hash varchar(191),
    object_id int(11) UNSIGNED,
    object_type varchar(32) NOT NULL,
    object_sub_type varchar(32),
    author_id int(11) UNSIGNED,
    post_parent int(11) UNSIGNED,
    title varchar(191),
    description text,
    breadcrumb_title varchar(191),
    post_status varchar(191),
    is_public tinyint(1),
    is_protected tinyint(1) DEFAULT ‘0’,
    has_public_posts tinyint(1),
    number_of_pages int(11) UNSIGNED,
    canonical mediumtext,
    primary_focus_keyword varchar(191),
    primary_focus_keyword_score int(3),
    readability_score int(3),
    is_cornerstone tinyint(1) DEFAULT ‘0’,
    is_robots_noindex tinyint(1) DEFAULT ‘0’,
    is_robots_nofollow tinyint(1) DEFAULT ‘0’,
    is_robots_noarchive tinyint(1) DEFAULT ‘0’,
    is_robots_noimageindex tinyint(1) DEFAULT ‘0’,
    is_robots_nosnippet tinyint(1) DEFAULT ‘0’,
    twitter_title varchar(191),
    twitter_image mediumtext,
    twitter_description mediumtext,
    twitter_image_id varchar(191),
    twitter_image_source varchar(191),
    open_graph_title varchar(191),
    open_graph_description mediumtext,
    open_graph_image mediumtext,
    open_graph_image_id varchar(191),
    open_graph_image_source varchar(191),
    open_graph_image_meta text,
    link_count int(11),
    incoming_link_count int(11),
    prominent_words_version int(11) UNSIGNED,
    PRIMARY KEY (id)) DEFAULT CHARSET=utf8; made by require_once(‘wp-admin/admin.php’), require_once(‘wp-load.php’), require_once(‘wp-config.php’), require_once(‘wp-settings.php’), do_action(‘plugins_loaded’), WP_Hook->do_action, WP_Hook->apply_filters, wpseo_init, YoastSEO, Yoast\WP\SEO\Main->load, Yoast\WP\SEO\Loader->load, Yoast\WP\SEO\Loader->load_initializers, Yoast\WP\SEO\Initializers\Migration_Runner->initialize, Yoast\WP\SEO\Initializers\Migration_Runner->run_free_migrations, Yoast\WP\SEO\Initializers\Migration_Runner->run_migrations, YoastSEO_Vendor\Ruckusing_Task_Manager->execute, YoastSEO_Vendor\Task_Db_Migrate->execute, YoastSEO_Vendor\Task_Db_Migrate->prepare_to_migrate, YoastSEO_Vendor\Task_Db_Migrate->run_migrations, WpYoastIndexable->up, WpYoastIndexable->add_table, YoastSEO_Vendor\Ruckusing_Adapter_MySQL_TableDefinition->finish, Yoast\WP\Lib\Ruckusing_Adapter->execute_ddl, Yoast\WP\Lib\Ruckusing_Adapter->query

    Ugh, no luck getting the debug log formatted properly.

    • This topic was modified 4 years, 6 months ago by ghassenpflug.
    • This topic was modified 4 years, 6 months ago by ghassenpflug.
    • This topic was modified 4 years, 6 months ago by ghassenpflug.
    • This topic was modified 4 years, 6 months ago by ghassenpflug.
    • This topic was modified 4 years, 6 months ago by ghassenpflug.
Viewing 8 replies - 1 through 8 (of 8 total)
  • Hi @ghassenpflug,

    We’re sorry you ran into this problem. Your proposed solution, removing the table and then recreating it will probably solve it. However, please only do this after creating a full backup of your database. That way you can always restore to the current situation.

    Please let us know if that solved the problem for you.

    Thread Starter ghassenpflug

    (@ghassenpflug)

    Hi, I used mysqldump to backup my database, then with the Yoast SEO plugin disabled, I did a table rename as follows:
    MariaDB [wp_database1]> rename table wpstg0_yoast_indexable to wpstg0_yoast_indexable_20200503;
    And checked the table no longer existed. However, on re-activating Yoast SEO plugin, I got the same error! The table was re-created:

    | wpstg0_yoast_indexable          |
    | wpstg0_yoast_indexable_20200503 |

    and error looks identical:

    [03-May-2020 08:23:37 UTC] WordPress database error Table ‘wpstg0_yoast_indexable’ already exists for query CREATE TABLE wpstg0_yoast_indexable (
    id int(11) UNSIGNED auto_increment NOT NULL,
    permalink mediumtext,
    permalink_hash varchar(191),
    object_id int(11) UNSIGNED,
    object_type varchar(32) NOT NULL,
    object_sub_type varchar(32),
    author_id int(11) UNSIGNED,
    post_parent int(11) UNSIGNED,
    title varchar(191),
    description text,
    breadcrumb_title varchar(191),
    post_status varchar(191),
    is_public tinyint(1),
    is_protected tinyint(1) DEFAULT ‘0’,
    has_public_posts tinyint(1),
    number_of_pages int(11) UNSIGNED,
    canonical mediumtext,
    primary_focus_keyword varchar(191),
    primary_focus_keyword_score int(3),
    readability_score int(3),
    is_cornerstone tinyint(1) DEFAULT ‘0’,
    is_robots_noindex tinyint(1) DEFAULT ‘0’,
    is_robots_nofollow tinyint(1) DEFAULT ‘0’,
    is_robots_noarchive tinyint(1) DEFAULT ‘0’,
    is_robots_noimageindex tinyint(1) DEFAULT ‘0’,
    is_robots_nosnippet tinyint(1) DEFAULT ‘0’,
    twitter_title varchar(191),
    twitter_image mediumtext,
    twitter_description mediumtext,
    twitter_image_id varchar(191),
    twitter_image_source varchar(191),
    open_graph_title varchar(191),
    open_graph_description mediumtext,
    open_graph_image mediumtext,
    open_graph_image_id varchar(191),
    open_graph_image_source varchar(191),
    open_graph_image_meta text,
    link_count int(11),
    incoming_link_count int(11),
    prominent_words_version int(11) UNSIGNED,
    PRIMARY KEY (id)) DEFAULT CHARSET=utf8; made by require_once(‘wp-admin/admin.php’), require_once(‘wp-load.php’), require_once(‘wp-config.php’), require_once(‘wp-settings.php’), do_action(‘plugins_loaded’), WP_Hook->do_action, WP_Hook->apply_filters, wpseo_init, YoastSEO, Yoast\WP\SEO\Main->load, Yoast\WP\SEO\Loader->load, Yoast\WP\SEO\Loader->load_initializers, Yoast\WP\SEO\Initializers\Migration_Runner->initialize, Yoast\WP\SEO\Initializers\Migration_Runner->run_free_migrations, Yoast\WP\SEO\Initializers\Migration_Runner->run_migrations, YoastSEO_Vendor\Ruckusing_Task_Manager->execute, YoastSEO_Vendor\Task_Db_Migrate->execute, YoastSEO_Vendor\Task_Db_Migrate->prepare_to_migrate, YoastSEO_Vendor\Task_Db_Migrate->run_migrations, WpYoastIndexable->up, WpYoastIndexable->add_table, YoastSEO_Vendor\Ruckusing_Adapter_MySQL_TableDefinition->finish, Yoast\WP\Lib\Ruckusing_Adapter->execute_ddl, Yoast\WP\Lib\Ruckusing_Adapter->query
    [03-May-2020 08:24:21 UTC] WordPress database error INDEX command denied to user ‘wpuser1’@’localhost’ for table ‘wpstg0_yoast_indexable’ for query CREATE INDEX object_type_and_sub_type ON wpstg0_yoast_indexable(object_type, object_sub_type) made by require_once(‘wp-admin/admin.php’), require_once(‘wp-load.php’), require_once(‘wp-config.php’), require_once(‘wp-settings.php’), do_action(‘plugins_loaded’), WP_Hook->do_action, WP_Hook->apply_filters, wpseo_init, YoastSEO, Yoast\WP\SEO\Main->load, Yoast\WP\SEO\Loader->load, Yoast\WP\SEO\Loader->load_initializers, Yoast\WP\SEO\Initializers\Migration_Runner->initialize, Yoast\WP\SEO\Initializers\Migration_Runner->run_free_migrations, Yoast\WP\SEO\Initializers\Migration_Runner->run_migrations, YoastSEO_Vendor\Ruckusing_Task_Manager->execute, YoastSEO_Vendor\Task_Db_Migrate->execute, YoastSEO_Vendor\Task_Db_Migrate->prepare_to_migrate, YoastSEO_Vendor\Task_Db_Migrate->run_migrations, WpYoastIndexable->up, WpYoastIndexable->add_table, WpYoastIndexable->add_indexes, YoastSEO_Vendor\Ruckusing_Migration_Base->add_index, Yoast\WP\Lib\Ruckusing_Adapter->add_index, Yoast\WP\Lib\Ruckusing_Adapter->execute_ddl, Yoast\WP\Lib\Ruckusing_Adapter->query

    To check, I moved the table again, with Yoast SEO deactivated, and waited a while, then re-activated Yoast SEO plugin, watching the DB with repeated use of “show tables”. I could see the table suddenly appear, so most certainly Yoast SEO plugin was creating it from scratch again. Yet the error persists.
    So I presume the error message is not the real cause of the error. There seems to be some issue with the installer logic?

    I included another error after that, which seems to be from clicking something in the admin screen (deactivation maybe, or something else). I include it for reference.

    Note I am using the latest version of the WP Staging plugin for my staging site, so it is a clone of the production site, with table prefixes “wpstg0_” in place of “wp_”.

    • This reply was modified 4 years, 6 months ago by ghassenpflug.
    • This reply was modified 4 years, 6 months ago by ghassenpflug.
    • This reply was modified 4 years, 6 months ago by ghassenpflug.
    • This reply was modified 4 years, 6 months ago by ghassenpflug.
    Plugin Support Md Mazedul Islam Khan

    (@mazedulislamkhan)

    Thanks for all the details. It sounds like a bug specific to the recent release and we’d be more than happy to investigate the issue further. Would it be possible for you to please submit a proper bug report directly at our GitHub development repository with all the informations you have gathered so far so that our development teams can surely look into this further?

    This will surely help us to troubleshoot further.

    Thread Starter ghassenpflug

    (@ghassenpflug)

    Done! First time, so please correct/request information as required.
    https://github.com/Yoast/wordpress-seo/issues/15064

    I have 11 databases all on the same MySQL server – all but 2 managed to update without a problem – all databases are identical in terms of their properties and permissions.

    If I delete Yoast completely and delete the associated tables and then restart MySQL and then install the plugin – none of the new tables are created and I get the dreaded warning notice – yet if I manually create the tables using SQL from one of the other databases there is no problem creating the tables – yet the error still shows and if I use the Yoast Test Helper plugin to reset the tables it just trashes them leaving .frm and .idb files in place.

    I have tried all of the solutions and none work – it would be helpful to know what the code is that generates the error and why the tables are not being created in the first place

    • This reply was modified 4 years, 6 months ago by daviddoughty.

    Just to update – one of the databases which updated OK yesterday – a wordpress multi-site – has now got all of its yoast indexable, indexible_hierarchy, migrations and primary_term tables reduced to .frm and .ibd – in other words trashed

    No error message on dashboard but “Click here to speed up your site” message has re-appeared (they had all been done yesterday) and clicking gives the indexing bar which just continues indexing.

    THERE IS SOMETHING SERIOUSLY WRONG WITH YOU CODE – PLEASE FIX

    Plugin Support devnihil

    (@devnihil)

    @daviddoughty Based on the information you provided, we expect this to be a bug. We’re actively using the bug tracking on our GitHub repository so your best next step would be to create a new issue for our developers at https://github.com/Yoast/wordpress-seo/issues/new. You will need an account to create a new issue. If this is your first bug report, please check out: https://kb.yoast.com/kb/how-to-write-a-good-bug-report/.

    Plugin Support devnihil

    (@devnihil)

    We are going ahead and marking this issue as resolved due to inactivity. If you require any further assistance please create a new issue.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘13.5 -> 14.0.4 upgrade error: wpstg0_yoast_indexable already exists’ is closed to new replies.