Wordfence Security
[resolved] PHP Error - wfDB (6 posts)

  1. contactmeviainternet
    Posted 3 years ago #

    This is a really great plug-in, but it isn't working with my installation on Hostgator.

    Since I installed, I'm getting PHP Warnings related to the mysql:
    "expects parameter 1 to be resource" in wfDB.php

    Any suggestions?


  2. Wordfence
    Plugin Author

    Posted 3 years ago #

    It looks like Wordfence is having trouble connecting to your database. Are you seeing any additional errors or just that one?



  3. contactmeviainternet
    Posted 3 years ago #

    Thanks for getting back to me.

    I'm also getting three other mysql related errors:

    PHP Warning: mysql_ping() expects parameter 1 to be resource, boolean given in wfDB.php on line 52

    PHP Warning: mysql_select_db(): supplied argument is not a valid MySQL-Link resource in wfDB.php on line 57

    PHP Warning: mysql_connect() [function.mysql-connect]: User x already has more than 'max_user_connections' active connections in wfDB.php on line 56

  4. Wordfence
    Plugin Author

    Posted 3 years ago #


    These are all related to the fact that Wordfence can't connect to your database. We have many customers on Hostgator who aren't experiencing problems, so I'd like to find out more about your configuration and why it's not able to connect to the database.

    Have you customized anything about your WordPress installation and the way it connects to the DB?



  5. sigepdewd
    Posted 3 years ago #

    I'm getting the same 3 errors. Have been for a month or so. It is constant recurring, and blows up my error logs by 30-40MB per day. Thing is, it only happens in my production installation. I have an exact replica running on a "test" environment with the same hosting company, and it is not giving me the errors.

    I even wiped out the wordpress directories and database in production and restored them. Still the same problem.

    What are these errors?

  6. contactmeviainternet
    Posted 3 years ago #

    I've done most of the suggestions mentioned in the Hardening WordPress article.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Wordfence Security
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic


No tags yet.