LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   MariaDB-10.2 unable to set max_connections and wait_timeout through etc/my.cnf (https://www.linuxquestions.org/questions/linux-newbie-8/mariadb-10-2-unable-to-set-max_connections-and-wait_timeout-through-etc-my-cnf-4175701729/)

taru.tarak 10-09-2021 01:46 AM

MariaDB-10.2 unable to set max_connections and wait_timeout through etc/my.cnf
 
Hello,

I am using Linux Amazon Linux 2 and MariaDB 10.2. I want to set value for max_connections and wait_timeout. But there no value set in my current etc/my.cnf file.

This is my etc/my.cnf:
Quote:

#cat /etc/my.cnf
#
# This group is read both both by the client and the server
# use it for options that affect everything
#
[client-server]

#
# This group is read by the server
#
[mysqld]
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0

#
# include all files from the config directory
#
!includedir /etc/my.cnf.d
It will be great help of someone please let me know how can I check my current value and set new value for both.

Thanks in advance.

bathory 10-09-2021 09:38 AM

Quote:

It will be great help of someone please let me know how can I check my current value and set new value for both.
In order to check current values log in the mariaDB server and run the following 2 commands:
Code:

SHOW VARIABLES LIKE "max_connections";
SHOW GLOBAL VARIABLES LIKE 'wait_timeout';

If you want to change the 1st add in the [mysqld] section:
Code:

max_connections=XXX
To change the 2nd, add under [mariadb] section:
Code:

wait_timeout=YYY
Regards

taru.tarak 10-09-2021 01:08 PM

Thank you so much. Really appreciated. Please take care and stay safe.
Regards,


All times are GMT -5. The time now is 05:43 AM.