Title: Multiple wrong Database prefix errors in my Apache logs / Bad Gateway errors
Last modified: December 22, 2016

---

# Multiple wrong Database prefix errors in my Apache logs / Bad Gateway errors

 *  Resolved [aseth181012](https://wordpress.org/support/users/aseth181012/)
 * (@aseth181012)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/multiple-wrong-database-prefix-errors-in-my-apache-logs-bad-gateway-errors/)
 * Hey there everyone,
 * at the moment I’ve two problems with my WordPress setup since I’ve installed 
   HMWP Pro on my network.
 * The first thing: I’ve got many errors in my Apache logs, like
 * > AH01071: Got error ‘PHP message: WordPress database error Table ‘wpdatabase.
   > wp_blogs’ doesn’t exist for query SELECT path FROM wp_blogs where blog_id >
   > 1 made by 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, HMWP_Controllers_Rewrite->hookPreload, HMWP_Models_Rewrite-
   > >buildRedirect\n’, referer: [https://&#8230](https://&#8230);./web/wp-admin/
   > network/plugin-install.php?s=Hide+my+wordpress&tab=search&type=term
 * My Plesk Panel suggested me to change my WordPress database prefix for security
   reasons, so I’ve done this step. Now since HMWP, my Apache log is “spamed” with
   these error messages.
 * The next problem, I’m getting NGINX 502 errors while logoff from my WordPress
   network. This also occured the first time since I’ve activated HMWP on my network.
   I’ve found an topic about this problem but the workaround which is suggested 
   there doesn’t work for me. As soon as I disaled HMWP again, the user logout works
   normally.
 * I think the NGINX 502 errors are associated with with these database prefix errors.
 * Is there any way to change this wrong database prefix?
 * Thanks and have a nice day,
 * Lucas
    -  This topic was modified 9 years, 5 months ago by [aseth181012](https://wordpress.org/support/users/aseth181012/).

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

 *  Plugin Author [John Darrel](https://wordpress.org/support/users/johndarrel/)
 * (@johndarrel)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/multiple-wrong-database-prefix-errors-in-my-apache-logs-bad-gateway-errors/#post-8592693)
 * Hey Lucas,
 * It’s strange that multisite didn’t install the wp_blogs table which stays for
   registering the sites you have in your network.
 * I will add a patch for that and yes, the logout can come from that error.
 * I will send you and email asap with the upgrade notice.
 * Best,
 * John
 *  Plugin Author [John Darrel](https://wordpress.org/support/users/johndarrel/)
 * (@johndarrel)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/multiple-wrong-database-prefix-errors-in-my-apache-logs-bad-gateway-errors/#post-8592732)
 * Lucas,
 * An upgrade should be available in your MU network plugins.
 * Please tell me if this patch fixed the logout issue also.
 * Best,
    John
 *  Thread Starter [aseth181012](https://wordpress.org/support/users/aseth181012/)
 * (@aseth181012)
 * [9 years, 5 months ago](https://wordpress.org/support/topic/multiple-wrong-database-prefix-errors-in-my-apache-logs-bad-gateway-errors/#post-8593806)
 * Hey John,
 * well, it seems that the database problem has been solved. But the 502 error while
   logout still occurs. I found some new nginx error in my logs everytime i try 
   to logout / reloading the logout page:
 * >  2016-12-27 16:08:48 Error 93.196.139.236 8596#0: *2312 upstream sent too big
   > header while reading response header from upstream nginx-error
   >  2016-12-27 
   > 16:13:04 Error 93.196.139.236 8596#0: *2450 upstream sent too big header while
   > reading response header from upstream nginx-error 2016-12-27 16:13:06 Error
   > 93.196.139.236 8596#0: *2453 upstream sent too big header while reading response
   > header from upstream nginx-error 2016-12-27 16:13:08 Error 93.196.139.236 8596#
   > 0: *2455 upstream sent too big header while reading response header from upstream
 * I’ve also tried to disable all plugins, like bbPress, BuddyPress, … But still
   502 errors…
 * Thanks,
    Lucas
    -  This reply was modified 9 years, 5 months ago by [aseth181012](https://wordpress.org/support/users/aseth181012/).
      Reason: Adding some additional details
 *  Plugin Author [John Darrel](https://wordpress.org/support/users/johndarrel/)
 * (@johndarrel)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/multiple-wrong-database-prefix-errors-in-my-apache-logs-bad-gateway-errors/#post-8614663)
 * Hey Lucas,
 * Can you increase the buffer size in the nginx config? It is too low and it may
   affect your loadin in the future.
 * Add this in the nginx config file in the http area.
    http { fastcgi_buffers 16
   16k; fastcgi_buffer_size 32k }
 * read more at: [http://stackoverflow.com/questions/23844761/upstream-sent-too-big-header-while-reading-response-header-from-upstream](http://stackoverflow.com/questions/23844761/upstream-sent-too-big-header-while-reading-response-header-from-upstream)
 * Best,
    John
 *  Thread Starter [aseth181012](https://wordpress.org/support/users/aseth181012/)
 * (@aseth181012)
 * [9 years, 4 months ago](https://wordpress.org/support/topic/multiple-wrong-database-prefix-errors-in-my-apache-logs-bad-gateway-errors/#post-8620132)
 * Hey John,
 * i was able to solve this error, however, not exactly with your solution.
    My 
   problem was solved after i’ve added these two lines in my nginx configuration.
 * proxy_buffers 16 16k;
    proxy_buffer_size 32k;
 * Maybe it has something to do with Parallels Plesk, nginx works as a reverse proxy
   on my server. Anyways, everything works fine now!
 * Thanks,
    Lucas
    -  This reply was modified 9 years, 4 months ago by [aseth181012](https://wordpress.org/support/users/aseth181012/).
 *  [advertiseit](https://wordpress.org/support/users/advertiseit/)
 * (@advertiseit)
 * [9 years, 1 month ago](https://wordpress.org/support/topic/multiple-wrong-database-prefix-errors-in-my-apache-logs-bad-gateway-errors/#post-9008727)
 * Hi Lucas,
 * Thank you!
 * That was just the solution I needed.
 * Thanks,
    Jason

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

The topic ‘Multiple wrong Database prefix errors in my Apache logs / Bad Gateway
errors’ is closed to new replies.

 * ![](https://ps.w.org/hide-my-wp/assets/icon-256x256.png?rev=3217792)
 * [WP Ghost (Hide My WP Ghost) - Security & Firewall](https://wordpress.org/plugins/hide-my-wp/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/hide-my-wp/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/hide-my-wp/)
 * [Active Topics](https://wordpress.org/support/plugin/hide-my-wp/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/hide-my-wp/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/hide-my-wp/reviews/)

 * 6 replies
 * 3 participants
 * Last reply from: [advertiseit](https://wordpress.org/support/users/advertiseit/)
 * Last activity: [9 years, 1 month ago](https://wordpress.org/support/topic/multiple-wrong-database-prefix-errors-in-my-apache-logs-bad-gateway-errors/#post-9008727)
 * Status: resolved