当前位置:网站首页>Reasons for MySQL reporting 1040too many connections and Solutions
Reasons for MySQL reporting 1040too many connections and Solutions
2022-07-01 13:04:00 【1024 questions】
Error reason :
terms of settlement
summary
MySQL Report errors 1040 ‘Too many connections’
Error reason :The actual number of connections exceeded mysql The maximum number of connections allowed , Too many visits ,MySQL Server can't resist .
terms of settlement1、 modify max_connections, If this value is already large ,2、 At this time, we should consider increasing the pressure of decentralized reading from the server ;
Windows find mysql.ini(Linux modify /etc/my.cnf file , stay [mysqld] Newly added max_connections=N). Modify the maximum number of connections allowed max_connections=N, The default is 100 Generally set to 500~1000 More appropriate ( This is based on the condition that the machine can support , Because if there are more connections , Be situated between MySQL A connection buffer is provided for each connection , It's going to cost more memory , So adjust the value properly , Do not blindly increase the set value .), The last restart mysql, Make sure you reboot .

net stop mysqlnet start mysql2、 Temporarily modify and view the maximum number of connections :
show variables like ‘%max_connections%';Wildcards view the number of connections in the current state , To determine the size of the value .
show global status like ‘Max_used_connections'; Modify the order :set global max_connections=1000;( restart mysql It will fail after service )

This is about MySQL Report errors 1040'Too many connections' That's all for the article about the reasons and solutions , More about MySQL Report errors 1040 Too many connections Please search the previous articles of software development network or continue to browse the relevant articles below. I hope you will support software development network more in the future !
边栏推荐
- Blocking sockets的读写操作该怎么玩?
- MySQL报错1040Too many connections的原因以及解决方案
- c语言学习
- Tencent always takes epoll, which is annoying
- ustime写出了bug
- When Sqlalchemy deletes records with foreign key constraints, the foreign key constraints do not work. What is the solution?
- GID: open vision proposes a comprehensive detection model knowledge distillation | CVPR 2021
- Look at the sky at dawn and the clouds at dusk, and enjoy the beautiful pictures
- 软件测试中功能测试流程
- Report on the "14th five year plan" and investment strategy recommendations for China's industrial robot industry 2022 ~ 2028
猜你喜欢

redis探索之缓存一致性

Mobile note application

【历史上的今天】7 月 1 日:分时系统之父诞生;支付宝推出条码支付;世界上第一支电视广告

Svg diamond style code

Operator-1 first acquaintance with operator

Hardware development notes (9): basic process of hardware development, making a USB to RS232 module (8): create asm1117-3.3v package library and associate principle graphic devices

软件测试中功能测试流程

Feign & Eureka & Zuul & Hystrix 流程

Based on the open source stream batch integrated data synchronization engine Chunjun data restore DDL parsing module actual combat sharing

VM虚拟机配置动态ip和静态ip访问
随机推荐
Detailed explanation of OSPF LSA of routing Foundation
基于.NetCore开发博客项目 StarBlog - (13) 加入友情链接功能
Perl 5.10.0 installation package download
题目 1004: 母牛的故事(递推)
波浪动画彩色五角星loader加载js特效
c语言学习
ROS2 Foxy depthai_ros教程
leetcode:329. 矩阵中的最长递增路径【dfs + cache + 无需回溯 + 优雅】
Ikvm of toolbox Net project new progress
System test UI test summary and questions (interview)
Router.use() requires a middleware function but got a Object
有没有大佬 遇到过flink监控postgresql数据库, 检查点无法使用的问题
localtime居然不可重入,踩坑了
Svg diamond style code
机器学习—性能度量
Feign & Eureka & zuul & hystrix process
Update a piece of data from the database. Will CDC get two pieces of data with OP fields D and C at the same time? I remember before, only OP was U
ustime写出了bug
R language uses conf of yardstick package_ The mat function calculates the confusion matrix of the multiclass model on each fold of each cross validation (or resampling), and uses the summary to outpu
Redis explores cache consistency