【发布时间】:2015-08-28 21:03:04
【问题描述】:
我确实有一个高度活跃的服务器,但无法重新启动它。很久以前,我已经激活了审核日志,但由于空间问题,我需要将其关闭。以下是我的变量;
审计日志缓冲区大小 | 1048576 | audit_log_connection_policy |全部 | 审计日志当前会话 |开 | audit_log_exclude_accounts | | 审计日志文件 |审计日志 | 审计日志刷新 |关闭 | 审计日志格式 |旧 | audit_log_include_accounts | | 审计日志政策 |全部 | audit_log_rotate_on_size | 0 | audit_log_statement_policy |全部 | 审计日志策略 |异步 |这是我的.cnf
plugin-load=audit_log.so
.
.
.
# Audit Log -
#--------------------------
#audit-log=FORCE_PLUS_PERMANENT
#audit_log_exclude_accounts=.....
#audit_log_file= /var/log/mysql/mysql_audit_db1.log
.
.
.
解决方案:
运行UNINSTALL PLUGIN audit_log; 后,它停止为我记录到 audit_log 文件。验证您是否可以使用SHOW PLUGINS;
mysql> UNINSTALL PLUGIN audit_log;
Query OK, 0 rows affected, 1 warning (0.00 sec)
mysql> show warnings;
Warning | 1620 | Plugin is busy and will be uninstalled on shutdown enter code here
【问题讨论】:
-
卸载插件 plugin_name;见:mariadb.com/kb/en/mariadb/uninstall-plugin
-
卸载插件链接信息听起来不是很动态且不可重启
-
我运行了这个命令,结果如下。它对我有用。不再记录 >>>>>>mysql> UNINSTALL PLUGIN audit_log;查询正常,0 行受影响,1 个警告(0.00 秒)>>>>>>>>mysql> 显示警告;警告 | 1620 |插件正忙,将在关机时卸载
标签: mysql space audit-logging