MySQL數據庫報以下錯誤-----------com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Data source rejected establishment of connection, message from server: "Too many connections"
MySQL安裝目錄下的my.ini中設定的併發鏈接數太少或者系統繁忙致使鏈接數被佔滿 mysql
解決方式:打開MySQL安裝目錄打開my.ini找到max_connections默認是100 通常設置到1000~2000比較合適,重啓mysql,這樣1040錯誤就解決啦。 sql
max_connections=2000 數據庫