记录一次mysql连接数最大告警
1、收到告警,mysql连接满了
以下是更改过程,不需要重启mysql,如果永久生效的话需要更改my.cnf文件。
mysql> show variables like '%max_connections%'; +-----------------+-------+ | Variable_name | Value | +-----------------+-------+ | max_connections | 151 | +-----------------+-------+ 1 row in set (0.00 sec) mysql> set GLOBAL max_connections = 300; Query OK, 0 rows affected (0.01 sec) mysql> show variables like '%max_connections%'; +-----------------+-------+ | Variable_name | Value | +-----------------+-------+ | max_connections | 300 | +-----------------+-------+ 1 row in set (0.00 sec) mysql> quit
浙公网安备 33010602011771号