This topic describes how to download the unencrypted data and log backup files of an ApsaraDB RDS for MySQL instance. You can archive the downloaded backup files. You can also restore data from the downloaded backup files to an on-premises database.

For more information about how to download the data and log backup files of an RDS instance that runs another database engine, see the following topics:

Limits

A RAM user that has only the read permissions is not authorized to download data or log backup files. You can grant the required permissions to the RAM user by using the RAM console. For more information, see Grant backup file download permissions to a RAM user with only read-only permissions.

Database engine Download of data backup files Download of log backup files
MySQL
  • If your RDS instance runs the High-availability or Enterprise Edition with local SSDs, you can download full physical backup files and full logical backup files.
  • If your RDS instance runs the Basic or High-availability Edition with standard or enhanced SSDs, you cannot download snapshot backup files.
    Note If your RDS instance uses standard or enhanced SSDs, you cannot download data backup files. You can restore the data of your RDS instance to a new RDS instance. You can also use Data Transmission Service (DTS) to migrate the data of your RDS instance to an on-premises database. For more information, see Restore the data of an ApsaraDB RDS for MySQL instance and Migrate RDS MySQ data to local MySQL by using backup files.
You can download log backup files without the need to consider the instance configuration.
Note For more information about how to view log backup files, see How do I use the mysqlbinlog command to view the binary logs of an RDS for MySQL instance?

Procedure

Note You can use Database Backup (DBS) to implement automated backup and automated download. For more information, see Back up one or more databases.
  1. Go to the Backup and Restoration page.
    1. Log on to the ApsaraDB for RDS console. In the left-side navigation pane, click Instances. In the top navigation bar, select the region where your RDS instance resides.
      选择地域
    2. Find your RDS instance and click its ID. In the left-side navigation pane, click Backup and Restoration.
  2. Click the Data Backup or Log Backup tab.
    • If you want to download a data backup file, click the Data Backup tab.
    • If you want to download a log backup file, click the Log Backup tab.
  3. Select a time range and click OK.
  4. Find the data or log backup file that you want to download. Then, click Download in the Actions column.
    Note
    • If you cannot find Download in the Actions column, you can see the "Limits" section of this topic.
    • If you want to download a data backup file that is used to restore data, we recommend that you select the data backup file that is created at the closest point in time.
    • If you want to download a log backup file that is used to restore data to an on-premises database, you must make sure that the following requirements are met:
      • The Instance ID on the Log Backup tab is the same as the Instance No. on the Data Backup tab.
      • The start time of the log backup file is later than the point in time when the selected data backup file is created. In addition, the start time of the log backup file must be earlier than the point in time to which you want to restore data.
  5. In the Download Instance Backup Set dialog box, click Download.
    Select a download method
    Download method Description
    Download Use a browser to download the backup file.
    Copy Internal URL Copy the internal URL that is used to download the backup file. If your Elastic Compute Service (ECS) and RDS instances reside in the same region, we recommend that you log on to the ECS instance. Then, you can use the internal URL to download the backup file on the ECS instance. This method is faster and more secure than the other download methods.
    Copy Public URL Copy the public URL that is used to download the backup file. If you want to use other tools to download the backup file, we recommend that you select this download method.
    Note If you are using a Linux operating system, you can run the following command to download a backup file:
    wget -c '<The URL that is used to download the backup file>' -O <The name of the backup file>
    • The -c parameter specifies to enable resumable download.
    • The -O parameter specifies to save the downloaded backup file by using a specified name. We recommend that you use the default file name that is provided in the specified URL.
    • If the specified URL contains more than one parameter, we recommend that you enclose the URL in a pair of single quotation marks ('). This prevents download failures.
    Download a data backup file

FAQ

  1. Why do I find two log backup files with the same name on the Log Backup tab?

    In the RDS High-availability Edition, your database system consists of one primary RDS instance and one secondary RDS instance. Both instances generate log backup files. Each log backup file is identified by an Instance ID on the Log Backup tab. The instance IDs allow you to distinguish between the log backup files from the primary RDS instance and those from the secondary RDS instance. On the Service Availability page, you can view the ID of the primary RDS instance in the Primary Instance No. field. On this page, you can also view the ID of the secondary RDS instance in the Secondary Instance No. field.

    Service Availability page in the original ApsaraDB RDS consoleService Availability page in the new ApsaraDB RDS console
  2. What do I do with the downloaded data and log backup files?

    You can use the downloaded data and log backup files to restore data. For more information, see Restore the data of an ApsaraDB RDS for MySQL instance from a physical backup file to a self-managed MySQL database and Restore the data of an ApsaraDB RDS for MySQL instance from a logical backup file to a self-managed MySQL instance.

  3. Why am I unable to find Download in the Actions column on the Data Backup or Log Backup tab of the Backup and Restoration page?

    If your RDS instance runs MySQL 5.7 or 8.0 on RDS Basic or High-availability Edition with standard or enhanced SSDs, you cannot download backup files. Therefore, you cannot find Download in the Actions column on the Data Backup or Log Backup tab of the Backup and Restoration page. However, you can restore the data of your RDS instance to a new RDS instance. You can also use DTS to migrate the data of your RDS instance to an on-premises database. For more information, see Restore the data of an ApsaraDB RDS for MySQL instance and Migrate data from RDS for MySQL to an on-premises MySQL database.

Related operations

Operation Description
Query backup sets Queries the data backup files of an ApsaraDB RDS instance.
Query log backup files Queries the log backup files of an ApsaraDB RDS instance.