[1040] PDOException in Connection.php line 528

SQLSTATE[08004] [1040] Too many connections

  1. try {
  2. if (empty($config['dsn'])) {
  3. $config['dsn'] = $this->parseDsn($config);
  4. }
  5. if ($config['debug']) {
  6. $startTime = microtime(true);
  7. }
  8. $this->links[$linkNum] = new PDO($config['dsn'], $config['username'], $config['password'], $params);
  9. if ($config['debug']) {
  10. // 记录数据库连接信息
  11. $this->log('[ DB ] CONNECT:[ UseTime:' . number_format(microtime(true) - $startTime, 6) . 's ] ' . $config['dsn']);
  12. }
  13. return $this->links[$linkNum];
  14. } catch (\PDOException $e) {
  15. if ($autoConnection) {

Call Stack

  1. in Connection.php line 528
  2. at PDO->__construct('mysql:host=127.0.0.1...', 'root', 'H0pe@2337877~', [0, 2, 0, ...]) in Connection.php line 528
  3. at Connection->connect() in Connection.php line 2024
  4. at Connection->initConnect(false) in Connection.php line 644
  5. at Connection->query('SELECT `url`,`urlnam...', ['ThinkBind_1_912756331_' => [1, 1], 'ThinkBind_2_1819594023_' => [0, 1], 'ThinkBind_3_425636653_' => [1, 1]], false, false) in Connection.php line 923
  6. at Connection->select(object(Query)) in Query.php line 3028
  7. at Query->select() in common.php line 9
  8. at getNavList(true) in 6594a09d75b28b790ff20ecde59df8b2.php line 190
  9. at include('D:\wwwroot\beisenzx....') in File.php line 59
  10. at File->read('D:\wwwroot\beisenzx....', ['city' => null, 'urlname' => 'hyxw73', 'cityName' => '', ...]) in Template.php line 226
  11. at Template->fetch('D:\wwwroot\beisenzx....', ['city' => null, 'urlname' => 'hyxw73', 'cityName' => '', ...], []) in Think.php line 93
  12. at Think->fetch('D:\wwwroot\beisenzx....', ['city' => null, 'urlname' => 'hyxw73', 'cityName' => '', ...], []) in View.php line 192
  13. at View->fetch('', ['city' => null, 'urlname' => 'hyxw73', 'cityName' => '', ...], [], false) in View.php line 42
  14. at View->output('') in Response.php line 396
  15. at Response->getContent() in Response.php line 128
  16. at Response->send() in index.php line 29

Environment Variables

GET Dataempty
POST Dataempty
Filesempty
Cookiesempty
Sessionempty
Server/Request Data
PATH C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\WindowsPowerShell\v1.0\
SYSTEMROOT C:\Windows
COMSPEC C:\Windows\system32\cmd.exe
PATHEXT .COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC
WINDIR C:\Windows
PHPRC D:/phpstudy_pro/Extensions/php/php7.0.9nts
_FCGI_SHUTDOWN_EVENT_ 12220
HTTP_CONNECTION close
SCRIPT_NAME /index.php
REQUEST_URI /art/hyxw73.html
QUERY_STRING
REQUEST_METHOD GET
SERVER_PROTOCOL HTTP/1.1
GATEWAY_INTERFACE CGI/1.1
REDIRECT_URL /art/hyxw73.html
REMOTE_PORT 56116
SCRIPT_FILENAME D:/wwwroot/beisenzx.cn/public/index.php
SERVER_ADMIN admin@example.com
CONTEXT_DOCUMENT_ROOT D:/wwwroot/beisenzx.cn/public
CONTEXT_PREFIX
REQUEST_SCHEME http
DOCUMENT_ROOT D:/wwwroot/beisenzx.cn/public
REMOTE_ADDR 54.211.203.45
SERVER_PORT 80
SERVER_ADDR 172.16.238.225
SERVER_NAME www.beisenzx.cn
SERVER_SOFTWARE Apache
SERVER_SIGNATURE
SystemRoot C:\Windows
HTTP_HOST www.beisenzx.cn
HTTP_USER_AGENT claudebot
HTTP_ACCEPT */*
REDIRECT_STATUS 200
REDIRECT_PATH_INFO art/hyxw73.html
FCGI_ROLE RESPONDER
PHP_SELF /index.php
REQUEST_TIME_FLOAT 1711619187.9986
REQUEST_TIME 1711619187
Environment Variablesempty
ThinkPHP Constants
DS \
APP_PATH D:\wwwroot\beisenzx.cn\public/../application/
CONF_PATH D:\wwwroot\beisenzx.cn\public/../config/
PUBILC_PATH D:\wwwroot\beisenzx.cn\public/
ROOT_PATH D:\wwwroot\beisenzx.cn\public
CACHE_PATH D:\wwwroot\beisenzx.cn\public/../runtime/
CONFIG_PATH D:\wwwroot\beisenzx.cn\public/../config/
UPLOAD_PATH uploads