I want to increase the max connection limit in mysql.
My current file /etc/my.cnf looks like this
[mysqld]
innodb_file_per_table=1
When I try to increase the connection limit by adding this variable then I cannot restart mysql service.
[mysqld]
innodb_file_per_table=1
set-variable=max_connections=10000
You can change the limit from your mysql config file which is located in where you have installed the mysql server database, .ini file
search for the max_connection variable and change the value as per your request
and you have restart your server after changing
Related
I am trying to update MySQL "innodb_buffer_pool_size" in windows server. I have run "set global innodb_buffer_pool_size=25610241024".
After I restart the server it's set back to 8M again.
If I change my.ini file then MySQL57 service is not running.
I am using MySQL 5.7.36.
To save setting, you need to put them in a my.ini file that the mysql server reads on startup.
SET GLOBAL... only affect the current running instance.
I am changing the value of group_concat_max_len to 15000 using
SET group_concat_max_len=15000;
I achieve what I what but when I restart mysql server, it is set to default 1024.
How can I make it static to 15000, I assume, I should be able to set this value in mysql config file. I added group_concat_max_len=15000 in my.cnf and restarted the server. The value remained same i.e 1024.
Can I set it in a way so that the value remains same when mysql server is restarted?
Yes. You need to put it in the config file :
LINUX: my.cnf file
WINDOWS: my.ini file
[mysqld]
group_concat_max_len=15000
Note: Add this line group_concat_max_len=15000 under mysqld section. You need to restart your MySQL server to see the effect.
I am using MySQL version:5.1.73
I want to change innodb_lock_wait_timeout mysql variable.
set innodb_lock_wait_timeout=100;
But I am getting this error:
#1238 - Variable 'innodb_lock_wait_timeout' is a read only variable
How can I fix this?
innodb_lock_wait_timeout variable in MySQL 5.1 is not dynamic, so you must specify it on command line when starting server:
mysqld --innodb_lock_wait_timeout=100
or in the configuration file (my.cnf, my.ini):
[mysqld]
innodb_lock_wait_timeout=100
restart MySQL server after configuration file change.
I have a MySQL Server version 5.5.25 installed on CentOS server.
I've increased *max_allowed_packet* size to 32M in /etc/my.cnf file in order to store it permanently (max_allowed_packet = 32M;), then I've restarted server with /etc/init.d/mysqld restart. The problem is that in PHPMyAdmin the value doesn't change. I tried to set variable from shell with SET GLOBAL max_allowed_packet = 33554432; (32 MB), but shell returns "0 rows affected".
Is it a bug of MySQL server? Or maybe I'm wrong?
Did you restart Apache?
service httpd restart
I'm editing my.cfg right now and I want to change the max # of connections.
# vi /etc/my.cnf
max_connections = 250
Open your MySQL configuration file in your favorite text editor and set the variable "max_connections" to the value you need. Once that's done, restart your MySQL daemon with /etc/init.d/mysqld restart (the init script path may differ on your system).