zoukankan      html  css  js  c++  java
  • Mysql ERROR 1040 (00000): Too many connections

    程序添加数据库数据:
    错误信息: com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Data source rejected establishment of connection,  message from server: "Too many connections"


    Navicat连接数据库报错
    错误信息: 1040 Too many connections


    重启Mysql :: mysql restart
    错误信息:mysql ERROR 1040 (00000): Too many connections




    当出现如下情况的时候,避免用户收到影响,先重启下Mysql服务
    [root@localhost ~]# service mysqld restart


    [root@localhost ~]# mysql
    mysql> select @@global.max_connections;
    +--------------------------------------+
    |  @@global.max_connections   |
    +--------------------------------------+
    |                                         100   |
    +--------------------------------------+

    // 也就是说现在的最大连接数是 100,我们把他修改为500,。


    mysql> set global max_connections=500;
    Query OK, 0 rows affected (0.00 sec)


    之前在google搜了很多解决方案,有人说修改/etc/my.cnf,据网上说完全没用(本人没有测试,也感觉有点麻烦)!


    有任何疑问,可以回复此贴进一步讨论。

    QQ交流群:18129647

    详细信息尽在 华夏编程社区(HackProLabs)  原文链接:http://cst21cn.5d6d.net/thread-2863-1-1.html

  • 相关阅读:
    JQuery学习四(过滤选择器)
    JQuery学习三(隐式迭代和节点遍历)
    JQuery学习二(获取元素控件并控制)
    JQuery学习一
    Dom中select练习
    DOM动态操纵控件案例
    DOM学习控件定位和案例
    DOM案例五星评分控件
    DOM动态增加控件
    DOM用TagName操作标签
  • 原文地址:https://www.cnblogs.com/dingchenghong/p/2694960.html
Copyright © 2011-2022 走看看