• The redirection tables (wp_X_redirection_404,wp_X_redirection_groups,wp_X_redirection_items,wp_X_redirection_logs,wp_X_redirects) don’t get created until visiting the ‘Settings’ -> ‘Redirection’ page to trigger the install method.

    This generates a lot of WordPress database errors:

    
    WordPress database error Table 'x.wp_2_redirection_items' doesn't exist for query SELECT wp_2_redirection_items.*,wp_2_redirection_groups.position AS group_pos FROM wp_2_redirection_items INNER JOIN wp_2_redirection_groups ON wp_2_redirection_groups.id=wp_2_redirection_items.group_id AND wp_2_redirection_groups.status='enabled' AND wp_2_redirection_groups.module_id=1 WHERE (wp_2_redirection_items.regex=1 OR wp_2_redirection_items.url='/xxx') made by require('wp-blog-header.php'), require_once('wp-load.php'), require_once('/xxx/wp-config.php'), require_once('wp-settings.php'), do_action('init'), WP_Hook->do_action, WP_Hook->apply_filters, WordPress_Module->init, Red_Item::get_for_url
    

    Would it be possible to create the tables on Network Activate / site creation, or to trigger the install method if the tables are not found?

    Thanks,
    Chris

    • This topic was modified 7 years, 5 months ago by chriswright.
Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author John Godley

    (@johnny5)

    Does this change do what you need?

    https://github.com/johngodley/redirection/pull/139

    It’s from last year and I haven’t got a multisite setup yet to test it.

    Thread Starter chriswright

    (@chriswright)

    A quick glance at that code looks like it covers the case of multi-sites on the first time the plugin is activated ??

    It doesn’t have the hook for when a new site is added though.

    I’ll test the code on one of our test sites and create a PR for the new site hook. If my testing comes back successful would you be happy to merge it, or would you prefer to wait until you have your own multi-site to test it?

    Hi, was this already fixed?

    Any status update on this one @johnny5, @chriswright? We have the same this issue on some multisites and would really like to address them. Any way we could help speeding this up for example?

    Regards Olaf

    Guys, I have some issue with my multisite, it’s not creating the new table when I add a new website to the network.
    @chriswright any luck?

    +1. Have a multisite installation with the same issue. @chriswright Is this planned at some point?

    FGD

    (@creativetopia)

    What is the deal-io with this? The Redirection plugin has bloated my error log file to 1.7GB on my multi-site in a course of 3 months. At this rate, I may just have to deactivate and wait for multi site support. Looking forward to a solution!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Database tables not created on multisites’ is closed to new replies.