1. mysql Error 1040 too many connection
當(dāng)最大連接數(shù)比較小時,可能會出現(xiàn)“1040 too many connection”錯誤。
解決方法:
- 首先需要重啟mysql服務(wù),執(zhí)行命令:service mysql restar
- 登錄mysql:mysql -uroot -p
- 登錄成功后執(zhí)行以下語句查詢當(dāng)前的最大連接數(shù):select VARIABLE_VALUE from information_schema.GLOBAL_VARIABLES where VARIABLE_NAME='MAX_CONNECTIONS';
- 執(zhí)行以下語句修改最大連接數(shù):set global max_connections = 3600;