All Products
Search
Document Center

ApsaraDB RDS:RDS MySQL log backups

Last Updated:Feb 28, 2026

ApsaraDB RDS for MySQL continuously uploads binary log files to backup storage in real time. These uploaded files are called log backup files. Combined with full data backups, log backup files enable you to restore instance data to a specific point in time within the backup retention period, accurate to seconds. The log backup feature is enabled by default.

Important

Disabling the log backup feature removes your ability to restore data to a specific point in time. The system automatically deletes all existing log backup files within 1 to 3 minutes. Deleted log backup files cannot be restored.

Billing

The log backup feature itself is free. However, log backup files consume backup storage. A free quota is provided. If the total size of data backup files and log backup files exceeds the free quota, additional fees apply. For details, see Backup storage fees.

Note

Log backup files are stored in backup storage, which is separate from the RDS instance storage. They do not consume instance storage capacity.

Enable or disable log backup

  1. Go to the Instances page. In the top navigation bar, select the region of the RDS instance. Find the instance and click its ID.

  2. In the left-side navigation pane, click Backup and Restoration.

  3. Click the Backup Strategy tab.

  4. In the Basic Backup section, click Edit.

  5. Configure the following parameters.

    Note

    For RDS instances running MySQL 5.7 on RDS Basic Edition, the retention period is fixed at 7 days.

    ParameterDescription
    Log BackupTurn the log backup feature on or off. Enabled by default.
    Log Backup Retention Period (Days)Number of days to retain log backup files. Valid values: 7 to 730. Default: 7. Must be less than or equal to the data backup retention period.
  6. Click OK.

Important

After you disable the log backup feature, the system automatically deletes existing log backup files within 1 to 3 minutes. Deleted log backup files cannot be restored.

Configure PITR

Point-in-time recovery (PITR) is an enhancement of the log backup feature. With PITR enabled, the system retains additional backup sets to ensure continuous data restoration to any point in time within the configured time range.

PITR is supported only in specific regions. For supported regions, differences between PITR and standard log backup, and eligibility requirements, see Configure the PITR feature.

Follow the same steps as enabling log backup (steps 1--4 above), then configure the following parameters:

ParameterDescription
Restoration to Specific Point in TimeTurn PITR on or off. Enabled by default for new RDS instances.
Time Range of Specific Points in Time for RestorationNumber of days during which data can be restored to any point in time. Valid values: 7 to 730. Default: 7. Must be less than or equal to the retention period of full backups. Modifying this value also modifies the log backup retention period.
Note

For RDS instances running MySQL 5.7 on RDS Basic Edition, the value is fixed at 7 days.

Important

The system retains additional backup sets beyond the configured time range to implement PITR. For example, if Time Range of Specific Points in Time for Restoration is set to 7, the system retains backup sets for 7 to 9 days. This includes one additional full backup retained for more than 7 days and all consecutive log backups generated from the seventh day to the day of the last full backup. Storage charges apply for this additional full backup and the extra log backups (generated over one week at most).

View log backup files

  1. Go to the Instances page. In the top navigation bar, select the region of the RDS instance. Find the instance and click its ID.

  2. In the left-side navigation pane, click Backup and Restoration.

  3. Click Base Backups, and then click the Log Backup tab.

For RDS High-availability Edition or RDS Enterprise Edition instances, log backup files are generated by both the primary and secondary instances. Check the instance ID of each log backup file to identify which instance generated it.

View total log backup size

  1. Go to the Instances page. In the top navigation bar, select the region of the RDS instance. Find the instance and click its ID.

  2. On the Basic Information page, find the Usage Statistics section. The total size of log backup files is displayed here.

Note
  • Log backup files are stored in backup storage and do not consume the storage capacity of the RDS instance. The backup storage is not directly accessible.

  • After a minor engine version update, the Backup Usage value on the Basic Information page may show as 0. This resolves automatically after the next scheduled backup completes.

Delete log backup files

For details, see Delete backup files or reduce the size of backup files.

Download log backup files

For details, see Download backup files.

Restore data to a specific point in time

With log backup enabled, you can restore instance data to a specific point in time, accurate to seconds. For details, see Restore full data and Restore individual databases and tables.

FAQ

Can I restore data from log backup files?

Yes. With log backup enabled, you can restore data to any point in time within the backup retention period, accurate to seconds. See Restore full data and Restore individual databases and tables.

Am I charged for the log backup feature?

No. The feature itself is free. However, log backup files consume backup storage. A free quota is provided. If the total size of data backup files and log backup files exceeds the free quota, additional fees apply. See Backup storage fees.

Why are no log backup files displayed on the Log Backup tab?

Two common causes:

  • The log backup feature is disabled. Enable it by following the steps in Enable or disable log backup.

  • The instance is newly created or the feature was recently enabled. Log backup files have not yet been uploaded to backup storage.

Why is the most recent log backup file missing from the Log Backup tab?

Only completed log backup files appear on the Log Backup tab. A file still being written to has not yet been uploaded to backup storage.

If the retention period is set to 7 days, can I access log backup files from exactly 7 days ago?

No. The system automatically deletes log backup files that exceed the retention period. Set the retention period based on your actual recovery needs.

What happens to log backup files when I disable the log backup feature?

The system automatically deletes all existing log backup files within 1 to 3 minutes. Deleted files cannot be restored.

Why did the size of log backup files suddenly increase?

Frequent data modifications (inserts, updates, and deletes) generate more binary log data, which increases log backup file size. To manage this, see Delete backup files or reduce the size of backup files.

Can I keep local binary log files without creating log backups?

Yes. Disable the log backup feature and configure a separate retention period for local log files. See Delete binary log files.

I disabled the log backup feature, but SHOW BINARY LOGS; still returns results. Why?

SHOW BINARY LOGS; queries local binary log files on the RDS instance, not log backup files in backup storage. These are different file sets. To delete local binary log files, see Delete the binary log files of an ApsaraDB RDS for MySQL instance.

I disabled the log backup feature, but no storage was released. Why?

Log backup files are stored in backup storage, which is separate from instance storage. Disabling the feature removes log backup files from backup storage but does not affect binary log files on the instance. Binary log files consume instance storage. To free instance storage, delete binary log files instead.

References

API reference

OperationDescription
DescribeBackupPolicyQuery the backup settings of an RDS instance.
ModifyBackupPolicyModify the backup settings of an RDS instance.