当前位置:网站首页>Increase the maximum number of MySQL connections
Increase the maximum number of MySQL connections
2022-06-12 15:06:00 【Ape fly】
1. Errors occurred
Too many connections
2. reason
One reason is MySQL In profile max_connections It's too small . Another reason , That is, the number of visits to the server is too high ,MySQL Server can't resist .
3. First determine the of the current machine mysql Is the maximum number of connections
show variables like '%max_connections%';
4. Set the maximum number of connections
4.1. Temporary settings are valid
set GLOBAL max_connections=1024;Then go and check , See if it works
show variables like '%max_connections%';Pay attention , This way of setting , once mysql After restart , In this way mysql Directly set variables will fail .
4.2. Permanent settings are valid
modify mysql The configuration file my.cnf, stay [mysqld] Section max_connections value .
max_connections=1024
After saving the configuration file , restart mysql that will do .
5. Enter server , View the number of accesses through the port
netstat -an | grep 3306 | grep ESTABLISHED | wc -l
6. You can also view the specific number of connections
show processlist;
Reference resources :MySQL: ERROR 1040: Too many connections - Simple books
边栏推荐
- Serialization and deserialization mechanism in terms of games
- Seaborn的简述
- Kinect2.0+ORBSLAM2_with_pointcloud_map
- Ali suggests that all POJO attributes use wrapper classes, but have you noticed these pits?
- First set and follow set in vernacular
- Element positioning of selenium
- 数组相关内容
- [SPARK][CORE] 面试问题之谈一谈Push-based shuffle
- USART(RS232422485)、I2C、SPI、CAN、USB总线
- 三维重建系统 | L3双视角运动恢复结构(SFM双目SFM)
猜你喜欢

IMU的学习记录

C 操作符

h3c GR5200路由器上如何设置公网ip可以访问

函数相关事项

Yiwei lithium energy plans to raise 9billion yuan: liujincheng and luojinhong jointly subscribe for 6billion yuan of layout Optical Valley

Qiming cloud sharing | demonstrate the switch through an example of the matter protocol to control the light on and off through the matter protocol

Qiming Zhixian shares the application scheme of 2.8-inch handheld central control screen

Kinect2.0+ORBSLAM2_with_pointcloud_map

Use of boost:: bind() in ROS

C escape character
随机推荐
SQL cross database injection
New关键字、引用&与指针的学习记录
Leader education was forced to be delisted: Softbank CMC suffered heavy losses only one year after listing
机器人前行、旋转的service编写
【Instant】1. Equivalent to date class 2 Represents a moment
模块八
TCP/IP 三次握手四次挥手(面试题)
掌门教育被强制退市:上市仅一年时间 软银CMC损失惨重
The process of generating strong association rules from frequent itemsets
About layoffs in Internet companies
The igatewayloadbalancer interface implements routing. Otherwise, it follows Sid routing
[LDA] rough version notes of EM variational reasoning [to be improved
PHPstudy建站提示hosts文件可能不存在或被阻止打开,同步hosts失败怎么解决
學習是一件逆人性的事情(成為高手的內功心法)
学习是一件逆人性的事情(成为高手的内功心法)
Understanding of Odom coordinate system
C data type
[wp][beginner level] attack and defense world game
安装PS软件时提示程序无法访问关键文件/目录,错误代码:41的解决方法
左对齐,右对齐,随机数,goto,比较输出bool