PHP Warning: mysql_connect(): Host 'dbserver.mydomain.com' is blocked because of

Discussion in 'Installation/Configuration' started by vaio1, Nov 19, 2011.

  1. vaio1

    vaio1 ISPConfig Developer ISPConfig Developer

    Hi guys,

    I get this error in the cron logs in the admin panel when I select the dbserver status logs.

    Code:
    PHP Warning: mysql_connect(): Host 'dbserver.mydomain.com' is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts' in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 78 
    I have already done the command suggested in both servers webserver and dbserver but nothing I get the same error message.

    Why?
     
  2. falko

    falko Super Moderator ISPConfig Developer

  3. vaio1

    vaio1 ISPConfig Developer ISPConfig Developer

    Hi,

    the problem is not the max connections that one user/client/software does, but the type of connections: wrong connections.
    Of course if we increase the max_connections value in the my.cnf the problem seems solved but after a while the problem
    will appear again.

    Code:
    mysql> show status like 'Conn%';
    +---------------+--------+
    | Variable_name | Value  |
    +---------------+--------+
    | Connections   | 126447 |
    +---------------+--------+
    1 row in set (0.00 sec)
    
    mysql> show global status like 'max%';
    +----------------------+-------+
    | Variable_name        | Value |
    +----------------------+-------+
    | Max_used_connections | 113   |
    +----------------------+-------+
    1 row in set (0.00 sec)
    
    
    The "Connections" value in the dbserver grows up visibly.

    Note: Infact the problem has appeared again.

    there is another error in the log messages:

    Code:
    PHP Warning: mysql_errno() expects parameter 1 to be resource, boolean given in /usr/local/ispconfig/server/lib/classes/db_mysql.inc.php on line 63
    
    What is that warning?
     
    Last edited: Nov 21, 2011

Share This Page