Hello seniors My site name is videos.3gx.in and after 2-3 days i face this problem user has exceeded the 'max_connections_per_hour' resource (current value 1) Please guyz help me I used Mysql-pdo and traffic 200 users and 1000 page-views per day Database entries 5lakh rows Hostgator shared plan Please help me to solve this problem
Need Urgent Help
Started on the old forum in December 2013 · view the original in the archive · old links redirect here
ok, i googled the error message n found this:
mysql - 'max_user_connections' set to 200 - still getting error - Stack Overflow
also, do you close the connection to database at bottom of page, this might help reduce the number of active connections
$link = mysql_connect('localhost', 'mysql_user', 'mysql_password'); //this code is for mysql, not mysql-pdo
if (!$link) {
die('Could not connect: ' . mysql_error());
}
echo 'Connected successfully';
mysql_close($link); //this line here is for mysql
FROM link above:
As for your "max connections" problem, it could be one of three things:
The server has too many open connections already. A MySQL server can only handle a specific number of open connections before refusing to allow any more, and this limit is shared amongst all users of the server. It's usually set quite high, although it's easily possible for someone to effectively DoS a MySQL server by making lots of connections (but see below)
Your user account has a limited number of connections allowed per hour - any further connections within that hour would be rejected. This is set on a per-user basis.
Your user accounts has a limited number of allowable open connections - any further connections would be rejected. This is set on a per-user basis.
so i guess maybe have a chat with hostgator too, but I'm guessing from the code and what i read, your account has a max limit on connections, so at an uneducated guess, try figure out how to close connections...
hope this helps...
C3 Themes: http://c3themes.wen.ru/index.html Find Files: http://mystarter.tk/?goto=X-search
Hostgator seem to be causing you many problems - maybe time for a host change?
something else wrote: Hostgator seem to be causing you many problems - maybe time for a host change?
Any idea please which host is best for me
I'm not the right person to ask that 😛 However you may wish to check gumslones post here