无法在 mysql 中设置线程堆栈大小 [英] Could not set thread-stack size in mysql

查看:86
本文介绍了无法在 mysql 中设置线程堆栈大小的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试增加 线程堆栈 变量.我可以使用命令行选项成功地做到这一点:

I'm trying to increase thread-stack variable. I can do it successfully using command-line option as such:

/usr/sbin/mysqld --thread-stack=256k

我也可以使用配置文件 /etc/init/mysql.conf/etc/init.d/mysql:

I can also do it using configuration files /etc/init/mysql.conf or /etc/init.d/mysql:

thread_stack=262144
thread_stack=256k
thread-stack=256k
thread-stack=262144

但是,通过/etc/mysql/my.cnf设置不起作用.show variables like '%thread_stack%'; 仍然显示默认的 196608.

However, setting through /etc/mysql/my.cnf doesn't work. show variables like'%thread_stack%'; still shows the default 196608.

为什么通过/etc/mysql/my.cnf设置不起作用?

我该如何解决这个问题?

How do I fix this?

(MySQL 5.5,5.5.38-0ubuntu0.14.04.1-log.)

(MySQL 5.5, 5.5.38-0ubuntu0.14.04.1-log.)

推荐答案

问题是为 mysql 运行的多个进程(线程).问题中 pgrep 的输出使我使用 kill -15 -1.

The issue was multiple processes(threads) running for mysql. The output of pgrep in the question led me to use kill -15 -1.

这会杀死应用程序的所有活动进程.然后我不得不重新启动 mysql 和 apache 并且我更新了值.

This kills all the active processes for applications. Then I had to restart mysql and apache and I had the value updated.

这篇关于无法在 mysql 中设置线程堆栈大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆