binlog_expire_logs_seconds
This page is part of MariaDB's Documentation.
The parent of this page is: System Variables for MariaDB Enterprise Server
Topics on this page:
Overview
DETAILS
The binlog_expire_logs_seconds
system variable can be used to configure the binlog expiration period with a temporal resolution of 1 second.
In versions with the binlog_expire_logs_seconds
system variable, the expire_binlog_expire_logs_seconds
system variable:
When the
binlog_expire_logs_seconds
system variable is set, the specified value in seconds is converted to the corresponding number of days, and the resulting floating point value is set to the expire_logs_ system variable.days When the expire_
logs_ system variable is set, the specified value in days is converted to the corresponding number of seconds, and the resulting integer value is set to thedays binlog_expire_logs_seconds
system variable.
Prior to this feature, the expire_
PARAMETERS
Command-line | --binlog_expire_logs_seconds=# |
Configuration file | Supported |
Dynamic | Yes |
Scope | Global |
Data Type | BIGINT UNSIGNED |
Minimum Value | 0 |
Maximum Value | 8553600 |
Product Default Value | 0 |
SKYSQL
EXAMPLES
SET GLOBAL binlog_expire_logs_seconds = 43200;
SHOW VARIABLES LIKE '%expire_logs%';
+----------------------------+----------+
| Variable_name | Value |
+----------------------------+----------+
| binlog_expire_logs_seconds | 43200 |
| expire_logs_days | 0.500000 |
+----------------------------+----------+
SET GLOBAL expire_logs_days = 10;
SHOW VARIABLES LIKE '%expire_logs%';
+----------------------------+-----------+
| Variable_name | Value |
+----------------------------+-----------+
| binlog_expire_logs_seconds | 864000 |
| expire_logs_days | 10.000000 |
+----------------------------+-----------+