Setting a Local Retention Period for MySQL Binlogs
Scenarios
RDS for MySQL deletes local binlogs after they are backed up to OBS. You can set the local retention period for binlogs as required to fully utilize the instance space.
Binlogs can be retained from 0 to 168 (7x24) hours locally.
The rules for deleting local binlogs are as follows:
- The binlogs used for replication between primary DB instances and standby DB instances or read replicas are not deleted, even when the retention period is set to 0.
- To reduce the risk of full disk space, you can submit a service ticket to enable the forceful binlog deletion function. If the local space usage exceeds 80%, local binlogs (excluding those used for primary/standby replication) will be deleted forcibly regardless of the retention period configured for local binlogs. If the local space usage exceeds 90%, local binlogs (including those used for primary/standby replication) will be deleted forcibly regardless of the local retention period. By default, the data is not forcibly cleared. You can submit a service ticket to enable this function.
Procedure
- Log in to the management console.
- Click in the upper left corner and select a region and a project.
- Click Service List. Under Database, click Relational Database Service. The RDS console is displayed.
- On the Instance Management page, click the target DB instance.
- In the navigation pane on the left, choose Backups & Restorations. On the Binlog Backups page, click Set Binlog Retention Period.
- In the displayed dialog box, set the local retention period and click OK.
Figure 1 Setting the binlog retention period
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot