遇见心流:Edwiin.cn

9 object(s)
 

Centos7环境中MariaDB:开启日志记录SQL

1.开启日志

MariaDB [(none)]> SET GLOBAL log_output = 'TABLE';
Query OK, 0 rows affected (0.000 sec)

MariaDB [(none)]> SET GLOBAL general_log = 'ON';
Query OK, 0 rows affected (0.000 sec)

2.查看日志表

select * from mysql.general_log;

查询结果截图: