Error
Error Code:
4113
MySQL Error 4113: Conflicting Binary Log Expiration
Description
This error indicates that you are attempting to configure two mutually exclusive system variables for binary log expiration: `expire_logs_days` and `binlog_expire_logs_seconds`. MySQL does not permit both options to be active concurrently, as they serve the same purpose with different granularities. It typically occurs during server startup, configuration changes, or when applying new settings.
Error Message
The option expire_logs_days cannot be used together with option binlog_expire_logs_seconds. To set one, first unset the other by setting it to 0.
Known Causes
3 known causesConflicting my.cnf Entries
Both `expire_logs_days` and `binlog_expire_logs_seconds` are specified with non-zero values in the MySQL server's configuration file (e.g., `my.cnf` or `my.ini`).
Dynamic Variable Contradiction
One binary log expiration variable is set in the configuration file, and an attempt is made to dynamically set the other using `SET GLOBAL` during runtime.
Automated Configuration Discrepancy
An automated script or configuration management tool inadvertently configures both `expire_logs_days` and `binlog_expire_logs_seconds` simultaneously.
Solutions
Coming SoonGeneral Troubleshooting Tips
- Check the error message carefully for specific details
- Review recent changes that might have caused the error
- Search for the exact error code in the official documentation
- Check log files for additional context
- Try restarting the application or service