Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
None
Description
The server_audit_file_rotate_now system variable is defined as PLUGIN_VAR_OPCMDARG:
static MYSQL_SYSVAR_BOOL(file_rotate_now, rotate, PLUGIN_VAR_OPCMDARG, |
"Force log rotation now.", NULL, rotate_log, FALSE); |
Since it is defined as PLUGIN_VAR_OPCMDARG, it means that users can set the system variable on the command-line and in the configuration file. However, it does not make sense to set this system variables on the command-line or in the configuration file.
This system variable should probably defined as PLUGIN_VAR_NOCMDOPT instead.
UPDATE: In fact it makes sence to specify the file_rotate_now=on at a startup. It would mean that server starts the new log after restart.
The problem though is that it doesn't work now as expected. If one does this - sets --server_audit_file_rotate_now=ON the rotation doesn't happen. Instead the value of the file_rotate_now variable becomes 1. That should be fixed.