Writing Logs Into Tables
Instructions on directing the General Query Log and Slow Query Log to tables (`mysql.general_log`, `mysql.slow_log`) instead of files using the `log_output=TABLE` system variable.
SET GLOBAL log_output = 'TABLE';
SET GLOBAL log_output = 'FILE,TABLE';ERROR 1556 (HY000): You can't use locks with log tables.SET GLOBAL general_log = 'OFF';
ALTER TABLE mysql.general_log ENGINE = MyISAM;
ALTER TABLE mysql.slow_log ENGINE = MyISAM;
SET GLOBAL general_log = @old_log_state;Last updated
Was this helpful?

