【问题标题】:How to increase the max_connections value for MySQL on Windows Server?如何在 Windows Server 上增加 MySQL 的 max_connections 值?
【发布时间】:2017-08-15 10:33:51
【问题描述】:

我有一个问题

SQLSTATE[08004] [1040] Too many connections

在 Windows Server 2008 r2 上。现在我正在尝试增加max_connections(默认值为151)。在 MySQL 5.6 根文件夹 D:\...\MySQL5.6 我找到了一个文件 my-default.ini 并添加了

max_connections = 200

[mysqld] 下。然后我重启了服务:

但什么都没有改变:

SHOW VARIABLES LIKE "max_connections";
+-----------------+-------+
¦ Variable_name   ¦ Value ¦
+-----------------+-------+
¦ max_connections ¦ 151   ¦
+-----------------+-------+

我将 my-default.ini 重命名为 my.ini 并再次重新启动 MySQL 服务器。没有效果。

如何在 Windows Server 上永久设置 MySQL max_connections

【问题讨论】:

    标签: mysql iis-6 windows-server-2008-r2 mysql-5.6 my.cnf


    【解决方案1】:

    我的错——我编辑了错误的my.ini

    在此video 中显示,如何找出Windows 上的MySQL 服务使用的是哪一个:

    1. [Start]->Run...->“services.msc”
    2. right click 在 MySQL 服务的入口处 -> Properties
    3. [tab] General:

    我更新了正确的my.ini 并重新启动了服务。现在正在使用新值。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2023-02-14
      • 2021-06-08
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多