This topic describes how to back up the data of an RDS for PPAS instance. You can specify a data and log backup cycle, according to which the system automatically backs up data and logs. Alternatively, you can manually back up the instance data.

Precautions

  • The backup files occupy the backup space of the RDS instance. If the used backup space exceeds the quota of free backup space, additional fees are incurred. For more information, see View the quota of free backup space for an RDS for PPAS instance.
  • For information about the billing method and billable items, see Billing methods and billable items.
  • For information about the pricing of backup space, see ApsaraDB RDS for MySQL pricing.
  • Do not perform DDL operations during the backup. Otherwise, tables are locked and consequently the backup fails.
  • Back up data and logs during off-peak hours.
  • If the data volume is large, the backup may take a long time.
  • Backup files are retained for a specified time period. Download the backup files to your computer before they are deleted.

Overview

DB engine Data backup Log backup
PPAS Supports full physical backup. A WAL file (16 MB/file) is compressed and uploaded immediately after it is generated. You must delete the file from your computer within 24 hours.

Set a backup policy for automatic backup

ApsaraDB for RDS can automatically back up databases according to the backup policy you set.

  1. Log on to the RDS console.
  2. Select the target region.选择地域
  3. Find the target RDS instance and click the instance ID.
  4. In the left-side navigation pane, click Backup and Restoration.
  5. On the Backup and Restoration page, click the Backup Settings tab. On the Backup Settings tab, click Edit.
  6. In the Backup Settings dialog box, set the backup parameters and click OK. The following table describes the parameters.
    Table 1. Backup parameters
    Parameter Description
    Data Retention Period The data retention period spans from 7 days to 730 days. The default retention period is 7 days.
    Note For MySQL 5.7 Basic Edition (with SSDs), the data retention period is 7 days and cannot be changed.
    Backup Cycle Select one or more workdays.
    Backup Time You can select any time period, which is measured in the unit of hour. We recommend that you select a time period during off-peak hours.
    Log Backup The status of the log backup function.
    Notice If you disable the log backup function, all log backup files are deleted and the time-based data restoration function becomes unavailable.
    Log Retention Period
    • The number of days in which log backup files are retained. The default retention period is 7 days.
    • The log retention period spans from 7 days to 730 days and must be shorter than or equal to the data retention period.
    Note For MySQL 5.7 Basic Edition (with SSDs), the log retention period is 7 days and cannot be changed.
    备份设置

Manually back up data

  1. Log on to the RDS console.
  2. Select the target region.选择地域
  3. Find the target RDS instance and click the instance ID.
  4. In the upper-right corner of the Basic Information page, click Back Up Instance.备份实例
  5. In the Back Up Instance dialog box, set the backup parameters and click OK.

FAQ

  1. Can I disable the data backup function for an RDS for PPAS instance?

    No, the data backup function must be enabled. However, you can lower the backup frequency to at least two times a week. The backup file retention period ranges from 7 days to 730 days.

  2. Can I disable the log backup function for an RDS for PPAS instance?

    Yes, you can disable the log backup function as needed.

APIs

API Description
CreateBackup Used to create a backup file for an RDS instance.
DescribeBackups Used to view the list of backup files for an RDS instance.
DescribeBackupPolicy Used to view the backup settings of an RDS instance.
ModifyBackupPolicy Used to modify the backup settings of an RDS instance.
DeleteBackup Used to delete the data backup files of an RDS instance.
DescribeBackupTasks Used to obtain the list of backup tasks for an RDS instance.
DescribeLogBackupFiles Used to obtain the log backup files of an RDS instance.