Support » Plugins and Hacks » [Resolved] [Plugin: Better WP Security] 'error'

[Resolved] [Plugin: Better WP Security] 'error'

  • Hello

    (I’m playing around with BWPS. I’ve set and unset a few things, and I have been doing it in batches here and there. I.e. I’m not 100% sure what I did to cause the error.)

    Visiting any admin page results in a single string response by the web server: ‘error’.

    From the error log:
    “WordPress database error Multiple primary key defined for query ALTER TABLE test_bwps_log ADD PRIMARY KEY id (id) made by require(‘wp-admin/plugins.php’), activate_plugin, do_action(‘activate_better-wp-security/better-wp-security.php’), call_user_func_array, bwps_setup::on_activate, bwps_setup->__construct, bwps_setup->activate_execute, dbDelta”

    I thought it was this at first:
    Is this because of “PRIMARY KEY id (id)” ?
    Which does not have 2 spaces as per spec:
    “You have to have two spaces between the words PRIMARY KEY and the definition of your primary key.”

    But I edited the plugin and tried – still no fish. Looks like something in the way dbdelta is parsing your create string?

    I have dropped the tables and re-activated, which works for now, but I’m not sure why it triggered the dbdelta..

    Long story there. Hope you enjoyed it. Anything I can do to help?


Viewing 15 replies - 1 through 15 (of 26 total)
  • Interesting. I’ll take a look. Thanks!

    that error same to me but its when you trying to login too many times then plugin ban you no matter that you are admin or not(maybe a glitch) and i haved same problem sometimes if my server need too much time to respond.That is one of the problem that i ran on to beside slowing my server after updating wp to 3.4.1 but this is for another topic 🙂 you must acces ftp and rename your wp-better-security to any other name then you can acces the site and after that rename it as it should be and that will do the job

    Sounds like I need to revisit the table creation query. Thanks for the info

    Sounds like I need to revisit the table creation query. Thanks for the info

    I too have encountered this ‘error’. It happened right after I was testing multiple login attempts just to see what would happen. But it is not only the admin area that appears as a blank page with the word ‘error’ on it but the entire website. I got the site working again by doing as alex80ks suggested and renaming the plugin via ftp in order to disable it that way. Then the site worked again and I could access admin again. But now whenever I rename the plugin folder back to ‘better-wp-security’ and reactivate the plugin, it goes back to the showing the ‘error’ message for the entire site! Is there something else that needs to be reset to get the plugin to work again? Is this error based on IP address or does the website go into error mode for everyone? If it’s the former then it’s not really a problem as long as we know how to reset it. But if it’s the latter, then obviously it’s a major problem.

    The error message should show for the entire site up to the point where the lockout expires. The thought being, if someone is trying that hard to get in one way, you don’t want them concentrating on anything else once they’re locked out.

    You can clear any lockout by clearing the bwps_lockouts table in your database.

    Now are ya’ll still seeing logged results on Good logins? I have yet to reproduce that one on any site.

    Sorry, I’ve not had time to revisit this. I think it might be possible to recreate the error by running the network update (network admin > updates > update network). But I’m not sure. If that works for you (i.e. network update runs without error), then it must be in combination with something else I am doing.

    It should’ve been fixed in 3.4.1. Can you confirm that is the version of Better WP Security you are running?


    I installed the latest version of this plugin earlier this evening. Everything seemed fine, and I happily configured a few things and left it active.

    About 15 minutes ago, I suddenly got the ‘error’ thing on every page of my website.

    I renamed the plugin folder to force it to deactivate, and my site came back, but I too get the ‘error’ message every time I try to reactivate is, so I can’t try changing any settings to see what caused it.

    I haven’t been trying any of the features e.g. the multiple login attempts, and i avoided activating anything that had a warning message about potential conflicts with server settings / other plugins.

    How do I reactivate this plugin without killing my entire website? :-/


    Update: found the problem – it was intrusion detection. There was a missing site asset causing a 404 that locked me out. All sorted now. Sorry!

    Glad it’s working. Unfortunately it isn’t an uncommon issue. I’m looking for a better way to detect in the future but doing so won’t happen as quickly as I would like.

    May be more common than you think, I also just got this mysterious “error” after simply clicking the button to activate all the basic security settings. Now I cannot get the plugin to work at all.

    I also got a site lockout notification, however I can still access the site… it may have something to do with the “error” though…

    I have used your plugin on other sites and it runs great. Not sure what happened here, just wanted to bring it to your attention when i found this thread.


    The ‘error’ can happen with one-click as it will turn on ‘404’ detection. Check your 404 log to see what it’s missing. In most cases there are left over artifacts (typically images) in the css files. This is unfortunately a problem in a lot of themes but also means that the 404 checking is doing it’s job. The most likely direction will be a timer that doesn’t activate it for an hour and instead emails the admin a list of the links if there could be a potential problem.

    Hi i am having the same issue but i don’t know how to fix it, is anyone able to elaborate for me as its becoming a large problem to my site i keep getting locked out, and other people on the site are getting locked out its basically displaying ‘error’ on a white page thats it, nothing else, can someone help as it goes after around 20 mins but this is putting people off using the website with the logic area, please can you help?

Viewing 15 replies - 1 through 15 (of 26 total)
  • The topic ‘[Resolved] [Plugin: Better WP Security] 'error'’ is closed to new replies.