+ Reply to Thread
Results 1 to 3 of 3

Thread: max_user_connections MYSQL

  1. #1

    max_user_connections MYSQL

    [Sat Dec 09 13:12:01.234736 2023] [proxy_fcgi:error] [pid 28120:tid 140245445932800] [client 185.191.171.9:0] AH01071: Got error 'PHP message: PHP Warning: mysqli_connect(): (HY000/1203): User databese_flynax already has more than 'max_user_connections' active connections in /home/mydomain/domains/domain.com/public_html/includes/classes/dbi.class.php on line 91'


    I encounter this problem every time Cronjob is run.
    ็How i can fix it ?

    I inquired with the server provider. The provider says the Script has a mySQL connection, but there is no disconnection. Therefore causing the connection to exceed the limit.

  2. #2
    Master
    Join Date
    Oct 2019
    Location
    Hungary
    Posts
    409
    Change provider. I did the same and haven't had any problems since.

  3. #3
    Probably the problem is that you have only a handful connections allowed and when your class tries to get a new connection you have this error.

    This is not a programming problem, just quantity of resources available. And any other script that uses this class are subject to have the error.

    You have to configure more connections on mysql config file on the server. If you don't have this access, ask the support to do it or change for a hosting company with more connections allowed!

    Other option is to implement a Singleton pattern on this class, so it reuses same pool of connections, and don't explode the limit.

    https://stackoverflow.com/questions/...tive-connectio

+ Reply to Thread