DBA Hub

📋Steps in this guide1/1

Find MySQL configuration values

Find MySQL / MariaDB configuration values

mysql configurationintermediate
by MYSQL
13 views
1

Find MySQL configuration values

1 . Get Config values from mysql prompt. 2. Alternatively you can check my.cnf file in /etc folder in Linux

Code/Command (click line numbers to comment):

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Find MySQL / MariaDB configuration values
MariaDB [(none)]>
SELECT VARIABLE_NAME,VARIABLE_VALUE FROM information_schema.GLOBAL_VARIABLES;
MariaDB [(none)]>
SELECT VARIABLE_NAME,VARIABLE_VALUE FROM information_schema.GLOBAL_VARIABLES WHERE Variable_Name = 'port';
+---------------+----------------+
| VARIABLE_NAME | VARIABLE_VALUE |
+---------------+----------------+
| PORT          | 3306           |
+---------------+----------------+
1 row in set (0.001 sec)
MariaDB [(none)]>
SELECT VARIABLE_NAME,VARIABLE_VALUE FROM information_schema.GLOBAL_VARIABLES WHERE Variable_Name = 'datadir';
+---------------+-------------------------------------+
| VARIABLE_NAME | VARIABLE_VALUE                      |
+---------------+-------------------------------------+
| DATADIR       | C:\Program Files\MariaDB 10.4\data\ |
+---------------+-------------------------------------+
1 row in set (0.001 sec)
cat /etc/my.cnf

Comments (0)

Please to add comments

No comments yet. Be the first to comment!