Tuesday, November 23, 2021

Increase mariadb max connections

 in 

[root@database-rhel84 my.cnf.d]# vi server.cnf

[root@database-rhel84 my.cnf.d]# pwd

/etc/my.cnf.d



# this is only for the mysqld standalone daemon

[mysqld]

datadir=/data/mysql-data

socket=/data/mysql-data/mysql.sock

innodb-page-size=32768

character-set-server=utf8

sql_mode='NO_BACKSLASH_ESCAPES'

innodb_strict_mode=0

lower_case_table_names = 1

max_connections=500



[root@database-rhel84 my.cnf.d]# mysql
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 3
Server version: 10.5.13-MariaDB MariaDB Server

Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> SET GLOBAL max_connections=500
    -> ;
Query OK, 0 rows affected (0.000 sec)


You can do the following to check:
MariaDB [(none)]> show variables





No comments:

Post a Comment