SQLSTATE[08004] [1040] Too many connections
I'm getting this error m开发者_C百科essages SQLSTATE[08004] [1040] Too many connections
, I'm using pdo adapter. Do I need to close connection? And how I do that?
In your my.conf file (usually located in /etc) find the line that says:
[mysqld]
And somewhere below that set
max_connections=500
Or whatever numeric value you need.
More information here: MySQL 5.5 Reference Manual: Too many connections.
You need change your my.cnf
file.
[mysqld]
set-variable=max_connections=250
Upper the value.
The root cause for this error for me was a full hard drive. Keep that in mind as a possibility.
In your mysql my must to run this:
Set Global max_connections=2000
I'm using phpMyAdmin and I executed
精彩评论