A backup policy template in Database Backup (DBS) contains configuration items for a backup schedule, such as the backup method, storage method, backup frequency, backup cycle, and backup start time. You must select a backup policy template when you create a backup schedule to back up databases. This topic describes how to create a backup policy template.

Procedure

  1. Log on to the DBS console. In the left-side navigation pane, click Backup Strategies. In the upper part of the page that appears, select a region.
  2. Click Add backup strategy.
  3. On the Create Policy Template page, create a backup policy template.
    Figure 1. Create a backup policy template
    Create a backup policy template
    1. Specify a name for the backup policy template.
    2. Select Logical Backup or Physical Backup.
      Note
      • Logical Backup: You can perform a logical backup on ApsaraDB RDS instances, PolarDB instances, ApsaraDB for Redis instances, ApsaraDB for MongoDB instances, self-managed databases in data centers, and self-managed databases hosted on Elastic Compute Service (ECS) instances.
      • Physical Backup: You can perform a physical backup only on self-managed databases.

      You cannot modify this parameter after the backup policy template is created. For more information, see Database engines and features.

    3. Click Modify to the right of backup policy. In the dialog box that appears, set the parameters for the backup policy. Then, click OK.
      Table 1. Parameter description
      Parameter Description
      Full Backup Method The method that is used to perform full backups. Valid values:
      • Periodic Backup: performs full backups on a specific periodic basis.
        Note If you set the Full Backup Method parameter to Periodic Backup, you must set the Full backup frequency parameter.
      • Single backup
      Full backup frequency

      The interval at which full backups are performed. Default value: Every Week. You must perform one to seven full backups every week.

      This parameter is displayed only when you set the Full Backup Method parameter to Periodic Backup.

      Full Backup Cycle

      The days of the week when full backups are performed. You can select one or more days of a week.

      Start At
      The start time of each full backup. You can select an exact hour of the day.
      Note If a previous full backup is not finished at the start time of the next full backup, DBS skips the next full backup.
      Incremental Backup Interval

      The interval at which incremental backups are performed. Unit: minutes. Valid values: 10, 20, 30, 40, 50, and 60. Default value: 10. If you set the interval to 10 minutes, DBS performs an incremental backup every 10 minutes.

      This parameter is displayed only when you select Physical Backup. If you select Logical Backup and enable the incremental backup feature for databases such as MySQL databases, incremental backups are performed in real time.

    4. Click Modify to the right of Level-1 Storage Pool (Backup). In the dialog box that appears, set the parameters for a level-1 storage pool. Then, click OK.
      Table 2. Parameter description
      Parameter Description
      Storage type
      The type of the storage that is used by data backups. Valid values: DBS Storage, NAS, and OSS For User.
      • You can back up data to NAS file systems or Object Storage Service (OSS) buckets only when you use the logical backup method.OSS For User
      • If the Storage type parameter is set to NAS for the level-1 storage pool, you cannot configure a level-2 storage pool.
      If you want to set this parameter to NAS or OSS For User, you must add OSS buckets or NAS file systems as DBS storage pools in advance. For more information, see Add and remove storage pools.
      Storage Pool

      The storage pool in which data backups are stored. You must select a storage pool that resides within the same region as the data source.

      You cannot modify this parameter after the backup policy template is created.
      Retention Period

      The duration for which full backups are retained. Valid values: 1 Week, 1 Month, 1 Quarter, 6 Months, 1 Year, 2 Years, 3 Years, 4 Years, 5 Years, 6 Years, 7 Years, 8 Years, 9 Years, and 10 Years. Default value: 2 Years.

      Encryption method Specifies whether and how to encrypt backups. Default value: Built-in encryption. Valid values:
      • Built-in encryption: Backups are encrypted.

        The server-side encryption feature of Object Storage Service (OSS) is used. When you upload an object to a bucket for which server-side encryption is enabled, OSS encrypts the object and stores the encrypted object. When you download the encrypted object from OSS, OSS decrypts the object and returns the decrypted object to you. For more information, see Server-side encryption.

      • Unencrypted: Backups are not encrypted.
  4. Click OK.
    A backup policy template is created.

What to do next

  • Back up a database: Select the created backup policy template when you create a backup schedule to back up the database. For more information, see Back up one or more databases.

  • View, modify, clone, or delete the created backup policy template on the Backup strategy list page.
    • After you modify the backup policy template, you can apply it only to the backup schedules that are created after the modification. Backup schedules that are created before the backup policy template is modified are not affected.

      You can modify the backup policy configured for a backup schedule in the Running state. For more information, see Modify the backup policy of a backup schedule.

    • If the backup policy template is associated with a backup schedule, you cannot delete the backup policy template.