WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Multisite wp-admin internal server error (500) after automatic 3.7.1 upgrade (16 posts)

  1. Keith Aldrich
    Member
    Posted 10 months ago #

    After the automatic 3.7.1 upgrade (got an email notifying me it automatically upgraded at 10 pm tonight MDT) I can't access wp-admin. I'm getting an internal server error (500).

    I'm using the WordPress MU Domain Mapping Plugin. I'm also using BulletProof Security.

    I'm having my host restore a backup...hopefully I can get in after that. But I'm just curious, has anyone else run into any issues with Multisite and 3.7.1?

  2. Keith Aldrich
    Member
    Posted 10 months ago #

    If this help.. the php5 error log in the wp-admin folder is showing the following errors.. right around the time of the automatic update.

    [31-Oct-2013 05:18:13 UTC] WordPress database error Duplicate column name 'signup_id' for query ALTER TABLE wp_signups ADD signup_id BIGINT(20) NOT NULL AUTO_INCREMENT PRIMARY KEY FIRST made by wp_upgrade, pre_schema_upgrade
    [31-Oct-2013 05:18:13 UTC] WordPress database error Can't DROP 'domain'; check that column/key exists for query ALTER TABLE wp_signups DROP INDEX domain made by wp_upgrade, pre_schema_upgrade
    [31-Oct-2013 05:18:13 UTC] WordPress database error Table 'wp_users' already exists for query CREATE TABLE wp_users (
      ID bigint(20) unsigned NOT NULL auto_increment,
      user_login varchar(60) NOT NULL default '',
      user_pass varchar(64) NOT NULL default '',
      user_nicename varchar(50) NOT NULL default '',
      user_email varchar(100) NOT NULL default '',
      user_url varchar(100) NOT NULL default '',
      user_registered datetime NOT NULL default '0000-00-00 00:00:00',
      user_activation_key varchar(60) NOT NULL default '',
      user_status int(11) NOT NULL default '0',
      display_name varchar(250) NOT NULL default '',
      spam tinyint(2) NOT NULL default '0',
      deleted tinyint(2) NOT NULL default '0',
      PRIMARY KEY  (ID),
      KEY user_login_key (user_login),
      KEY user_nicename (user_nicename)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 05:18:13 UTC] WordPress database error Table 'wp_usermeta' already exists for query
    CREATE TABLE wp_usermeta (
      umeta_id bigint(20) unsigned NOT NULL auto_increment,
      user_id bigint(20) unsigned NOT NULL default '0',
      meta_key varchar(255) default NULL,
      meta_value longtext,
      PRIMARY KEY  (umeta_id),
      KEY user_id (user_id),
      KEY meta_key (meta_key)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 05:18:13 UTC] WordPress database error Table 'wp_blogs' already exists for query
    CREATE TABLE wp_blogs (
      blog_id bigint(20) NOT NULL auto_increment,
      site_id bigint(20) NOT NULL default '0',
      domain varchar(200) NOT NULL default '',
      path varchar(100) NOT NULL default '',
      registered datetime NOT NULL default '0000-00-00 00:00:00',
      last_updated datetime NOT NULL default '0000-00-00 00:00:00',
      public tinyint(2) NOT NULL default '1',
      archived tinyint(2) NOT NULL default '0',
      mature tinyint(2) NOT NULL default '0',
      spam tinyint(2) NOT NULL default '0',
      deleted tinyint(2) NOT NULL default '0',
      lang_id int(11) NOT NULL default '0',
      PRIMARY KEY  (blog_id),
      KEY domain (domain(50),path(5)),
      KEY lang_id (lang_id)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 05:18:13 UTC] WordPress database error Table 'wp_blog_versions' already exists for query
    CREATE TABLE wp_blog_versions (
      blog_id bigint(20) NOT NULL default '0',
      db_version varchar(20) NOT NULL default '',
      last_updated datetime NOT NULL default '0000-00-00 00:00:00',
      PRIMARY KEY  (blog_id),
      KEY db_version (db_version)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 05:18:13 UTC] WordPress database error Table 'wp_registration_log' already exists for query
    CREATE TABLE wp_registration_log (
      ID bigint(20) NOT NULL auto_increment,
      email varchar(255) NOT NULL default '',
      IP varchar(30) NOT NULL default '',
      blog_id bigint(20) NOT NULL default '0',
      date_registered datetime NOT NULL default '0000-00-00 00:00:00',
      PRIMARY KEY  (ID),
      KEY IP (IP)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 05:18:13 UTC] WordPress database error Table 'wp_site' already exists for query
    CREATE TABLE wp_site (
      id bigint(20) NOT NULL auto_increment,
      domain varchar(200) NOT NULL default '',
      path varchar(100) NOT NULL default '',
      PRIMARY KEY  (id),
      KEY domain (domain,path)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 05:18:13 UTC] WordPress database error Table 'wp_sitemeta' already exists for query
    CREATE TABLE wp_sitemeta (
      meta_id bigint(20) NOT NULL auto_increment,
      site_id bigint(20) NOT NULL default '0',
      meta_key varchar(255) default NULL,
      meta_value longtext,
      PRIMARY KEY  (meta_id),
      KEY meta_key (meta_key),
      KEY site_id (site_id)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 05:18:13 UTC] WordPress database error Table 'wp_signups' already exists for query
    CREATE TABLE wp_signups (
      signup_id bigint(20) NOT NULL auto_increment,
      domain varchar(200) NOT NULL default '',
      path varchar(100) NOT NULL default '',
      title longtext NOT NULL,
      user_login varchar(60) NOT NULL default '',
      user_email varchar(100) NOT NULL default '',
      registered datetime NOT NULL default '0000-00-00 00:00:00',
      activated datetime NOT NULL default '0000-00-00 00:00:00',
      active tinyint(1) NOT NULL default '0',
      activation_key varchar(50) NOT NULL default '',
      meta longtext,
      PRIMARY KEY  (signup_id),
      KEY activation_key (activation_key),
      KEY user_email (user_email),
      KEY user_login_email (user_login,user_email),
      KEY domain_path (domain,path)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 06:01:59 UTC] WordPress database error Duplicate column name 'signup_id' for query ALTER TABLE wp_signups ADD signup_id BIGINT(20) NOT NULL AUTO_INCREMENT PRIMARY KEY FIRST made by wp_upgrade, pre_schema_upgrade
    [31-Oct-2013 06:01:59 UTC] WordPress database error Can't DROP 'domain'; check that column/key exists for query ALTER TABLE wp_signups DROP INDEX domain made by wp_upgrade, pre_schema_upgrade
    [31-Oct-2013 06:01:59 UTC] WordPress database error Table 'wp_users' already exists for query CREATE TABLE wp_users (
      ID bigint(20) unsigned NOT NULL auto_increment,
      user_login varchar(60) NOT NULL default '',
      user_pass varchar(64) NOT NULL default '',
      user_nicename varchar(50) NOT NULL default '',
      user_email varchar(100) NOT NULL default '',
      user_url varchar(100) NOT NULL default '',
      user_registered datetime NOT NULL default '0000-00-00 00:00:00',
      user_activation_key varchar(60) NOT NULL default '',
      user_status int(11) NOT NULL default '0',
      display_name varchar(250) NOT NULL default '',
      spam tinyint(2) NOT NULL default '0',
      deleted tinyint(2) NOT NULL default '0',
      PRIMARY KEY  (ID),
      KEY user_login_key (user_login),
      KEY user_nicename (user_nicename)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 06:01:59 UTC] WordPress database error Table 'wp_usermeta' already exists for query
    CREATE TABLE wp_usermeta (
      umeta_id bigint(20) unsigned NOT NULL auto_increment,
      user_id bigint(20) unsigned NOT NULL default '0',
      meta_key varchar(255) default NULL,
      meta_value longtext,
      PRIMARY KEY  (umeta_id),
      KEY user_id (user_id),
      KEY meta_key (meta_key)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 06:01:59 UTC] WordPress database error Table 'wp_blogs' already exists for query
    CREATE TABLE wp_blogs (
      blog_id bigint(20) NOT NULL auto_increment,
      site_id bigint(20) NOT NULL default '0',
      domain varchar(200) NOT NULL default '',
      path varchar(100) NOT NULL default '',
      registered datetime NOT NULL default '0000-00-00 00:00:00',
      last_updated datetime NOT NULL default '0000-00-00 00:00:00',
      public tinyint(2) NOT NULL default '1',
      archived tinyint(2) NOT NULL default '0',
      mature tinyint(2) NOT NULL default '0',
      spam tinyint(2) NOT NULL default '0',
      deleted tinyint(2) NOT NULL default '0',
      lang_id int(11) NOT NULL default '0',
      PRIMARY KEY  (blog_id),
      KEY domain (domain(50),path(5)),
      KEY lang_id (lang_id)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 06:01:59 UTC] WordPress database error Table 'wp_blog_versions' already exists for query
    CREATE TABLE wp_blog_versions (
      blog_id bigint(20) NOT NULL default '0',
      db_version varchar(20) NOT NULL default '',
      last_updated datetime NOT NULL default '0000-00-00 00:00:00',
      PRIMARY KEY  (blog_id),
      KEY db_version (db_version)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 06:01:59 UTC] WordPress database error Table 'wp_registration_log' already exists for query
    CREATE TABLE wp_registration_log (
      ID bigint(20) NOT NULL auto_increment,
      email varchar(255) NOT NULL default '',
      IP varchar(30) NOT NULL default '',
      blog_id bigint(20) NOT NULL default '0',
      date_registered datetime NOT NULL default '0000-00-00 00:00:00',
      PRIMARY KEY  (ID),
      KEY IP (IP)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 06:01:59 UTC] WordPress database error Table 'wp_site' already exists for query
    CREATE TABLE wp_site (
      id bigint(20) NOT NULL auto_increment,
      domain varchar(200) NOT NULL default '',
      path varchar(100) NOT NULL default '',
      PRIMARY KEY  (id),
      KEY domain (domain,path)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 06:01:59 UTC] WordPress database error Table 'wp_sitemeta' already exists for query
    CREATE TABLE wp_sitemeta (
      meta_id bigint(20) NOT NULL auto_increment,
      site_id bigint(20) NOT NULL default '0',
      meta_key varchar(255) default NULL,
      meta_value longtext,
      PRIMARY KEY  (meta_id),
      KEY meta_key (meta_key),
      KEY site_id (site_id)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
    [31-Oct-2013 06:01:59 UTC] WordPress database error Table 'wp_signups' already exists for query
    CREATE TABLE wp_signups (
      signup_id bigint(20) NOT NULL auto_increment,
      domain varchar(200) NOT NULL default '',
      path varchar(100) NOT NULL default '',
      title longtext NOT NULL,
      user_login varchar(60) NOT NULL default '',
      user_email varchar(100) NOT NULL default '',
      registered datetime NOT NULL default '0000-00-00 00:00:00',
      activated datetime NOT NULL default '0000-00-00 00:00:00',
      active tinyint(1) NOT NULL default '0',
      activation_key varchar(50) NOT NULL default '',
      meta longtext,
      PRIMARY KEY  (signup_id),
      KEY activation_key (activation_key),
      KEY user_email (user_email),
      KEY user_login_email (user_login,user_email),
      KEY domain_path (domain,path)
    ) DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci made by wp_upgrade, make_db_current_silent, dbDelta
  3. I saw similar errors with someone using an old events calendar.

    Turn off ALL the plugins. See if that works. Then turn them on one at a time till it breaks again.

  4. Keith Aldrich
    Member
    Posted 9 months ago #

    I actually resolved it by restoring a database backup. Unfortunately I couldn't get into the WP-Admin area at all...

    At some point since October 1, something broke the database...at this point I'm not sure what happened.

    I had my host restore a copy of the database from about 4 days before the update. It was broken... some of the _options tables were missing a ton of fields.

    Luckily I had a db from the start of October that was solid..restored that and I am back up...for now (knock on wood).

    Because the DB was broken BEFORE the 3.7.1 update.. I can say it wasn't 3.7.1. Although it might have been 3.7 because it looks like it broke around the time 3.7 was released.

    Currently the site is on 3.6... I'm going to try upgrading to 3.7 again and cross my fingers that it was a one time deal.

    If upgrading to 3.7 does break it I'll post again.

  5. FYI disabling plugins when you can't log in to the site is done by renaming the plugins folder.

  6. Keith Aldrich
    Member
    Posted 9 months ago #

    Turns out this was my problem. Not plugin related.

    http://wordpress.org/support/topic/getting-error-fatal-error-cannot-redeclare-check_password_reset_key?replies=26#post-4835971

    If you've renamed your wp-login.php (for security reason) then 3.7.1 can break your wp-admin.

    I tried this fixes in there but still having issues. Restoring backup again....

  7. There is NO security benefit in renaming wp-login.php

    You've still gotta log in, right? So wp-admin redirects and oh look! I found your login page :D

  8. Keith Aldrich
    Member
    Posted 9 months ago #

    Ya, but it is kind of inconvenient when your host blocks access to wp-login.php because of a brute force attack on your shared hosting and you can't get into the back-end of your site.

  9. Ya, but it is kind of inconvenient when your host blocks access to wp-login.php because of a brute force attack on your shared hosting and you can't get into the back-end of your site.

    o.O

    Leave that host. That is just flat out stupid. Any decent host should be filtering attacks via their firewall (mod_security at the very least).

    What issues are you still having. The original ones or something new?

  10. Keith Aldrich
    Member
    Posted 9 months ago #

    Ya, they also blacklisted my IP once when I crawled my site for broken links :)

    Other than those two issues I've had great luck with them. I can't complain too much because it isn't very expensive...if I had the cash I'd pay for dedicated hosting.

    Right now, I've got everything running smoothly...for the time being. Once I tracked down that the issue was with wp-login being changed prior to updating I was able to get it working again via some advice on the linked thread, and also a couple of extra steps (due to W3 Total Cache and BPS).

    I guess this teaches me not to mess with core files, even if I have good intentions.

    Thanks for you help!

  11. Ya, they also blacklisted my IP once when I crawled my site for broken links :)

    Okay, THAT I can see. broken link checkers are brutal on servers :/

    I would ask your host to UNlock the wp-login (since they;re literally breaking WP by doing that), and then maybe use a htpasswd block for it. You can use the tricks here: http://halfelf.org/2013/wp-login-protection-htaccess/

  12. Keith Aldrich
    Member
    Posted 9 months ago #

    Ya, I've actually got the whole wp-admin folder blocked with deny all, except for my white listed IPs. Unfortunately they had shut down wp-login server wide because of a botnet bruteforce attack that was affecting several sites...and even though I had mine secure it got blocked too.

    They've only done this temporarily, twice...but both times I was trying to get in, which is what prompted me to change wp-login file name and setup a filter in functions to change wp-login references server wide.

    I don't know if it was the filter or file name change that broke the backend of the site when I upgraded to 3.7.1, but one of them did. Funny thing is I've had this setup since 3.5 and upgraded through 3.6 & 3.7 w/ no issues and it wasn't until 3.7.1 that I had problems.

    I guess that's one of the downsides of shared hosting...

    Nice website BTW.

  13. jorgeorpinel
    Member
    Posted 3 months ago #

    I'm getting a very similar problem to yours but I didn't rename any core files. With SOME users (roles below admin) I get a blank page after login (silent 502 error).

    In my case it may be related to plugins because login works with no plugins but I haven't found a specific culprit. I'm currently running 3.9 but this started heppening back when I was in 3.8.x which I upgraded to from 3.7.1.

    My wp debug.log constantly outputs:

    WordPress database error Duplicate column name 'signup_id' for query ALTER TABLE wp_signups ADD signup_id BIGINT(20) NOT NULL AUTO_INCREMENT PRIMARY KEY FIRST made by wp_upgrade, pre_schema_upgrade
    
    WordPress database error Can't DROP 'domain'; check that column/key exists for query ALTER TABLE wp_signups DROP INDEX domain made by wp_upgrade, pre_schema_upgrade
    
    WordPress database error Duplicate key name 'domain_path' for query ALTER TABLE wp_signups ADD KEY domain_path (domain,path) made by wp_upgrade, make_db_current_silent, dbDelta

    ALSO, even when disabling plugins, I randomly get:

    PHP Notice:  wpdb::prepare was called <strong>incorrectly</strong>. The query argument of wpdb::prepare() must have a placeholder. Please see <a href="http://codex.wordpress.org/Debugging_in_WordPress">Debugging in WordPress</a> for more information. (This message was added in version 3.9.) in ...\wp-includes\functions.php on line ...

    So 2 recommendations, 1 ALWAYS backup before upgrading any wp versions, the process is not nearly as safe as wordpress.org claims. And 2 Don't use 3.9 yet, that last notice is annoyingly erratic.

  14. jorgeorpinel
    Member
    Posted 3 months ago #

    p.s. the login works actually, to be more clear. /wp-admin/ just doesn't display. I'm re-enabling plugin by plugin to figure this out.

  15. jorgeorpinel
    Member
    Posted 3 months ago #

    Ok some pretty ridiculous things are happening such 'PHP Notice: wpdb::prepare was called ...' notices only appearing when certain plugins are NOT activated (e.g. BlackBox), what?

    Btw in case this is a database corruption problem, I previously tried running again the wp db updater at /wp-admin/(network/)upgrade.php (both for the site and entire network). It ran but nothing changed. I also tried the WP_ALLOW_REPAIR + /wp-admin/maint/repair.php method (only available at site level), to no avail. If there are db problems still such as with the _options like @keith-aldrich mentioned, those methods don't seem to fix it (but actually they seem alright according to codex.wordpress.org/Database_Description). I have no relevant backups.

    ---

    Being all that said, my problem currently seems to be with a couple of custom plugins I created, one of which I changed recently but the other one hasn't changed in months and didn't use to cause this that I remember. I will check if the same plugins break other sites as well...

  16. jorgeorpinel
    Member
    Posted 3 months ago #

    Quick update: Just upgraded to 3.9.1 , same problem.

Reply

You must log in to post.

About this Topic

Tags

No tags yet.