You can call the DescribeCrossRegionBackups operation to query the cross-region data backup files of an instance.
For more information about how to query the cross-region log backup files of an RDS instance, see DescribeCrossRegionLogBackupFiles.
Before you call this operation, make sure that the instance runs one of the following database engines:
- MySQL. For more information, see Back up an ApsaraDB RDS for MySQL instance across regions.
- SQL Server. For more information, see Back up an ApsaraDB RDS for SQL Server instance across regions.
- PostgreSQL. For more information, see Back up an ApsaraDB RDS for PostgreSQL instance across regions.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | DescribeCrossRegionBackups |
The operation that you want to perform. Set the value to DescribeCrossRegionBackups. |
DBInstanceId | String | Yes | rm-uf6wjk5xxxxxxxxxx |
The ID of the instance. |
RegionId | String | Yes | cn-hangzhou |
The region ID of the instance. |
CrossBackupRegion | String | No | cn-shanghai |
The ID of the destination region where the cross-region data backup file is stored. |
CrossBackupId | Integer | No | 14562 |
The ID of the cross-region data backup file. Note You must specify the CrossBackupId parameter. Alternatively, you must specify the StartTime and EndTime parameters.
|
StartTime | String | No | 2019-05-30T12:10:00Z |
The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC. |
EndTime | String | No | 2019-06-15T12:10:00Z |
The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC. |
PageSize | Integer | No | 30 |
The number of entries to return on each page. Valid values:
Default value: 30. |
PageNumber | Integer | No | 1 |
The number of the page to return. Valid values: any non-zero positive integer. Default value: 1. |
BackupId | Integer | No | 603524*** |
The ID of the cross-region data backup file. |
ResourceGroupId | String | No | rg-acfmy***** |
The ID of the resource group. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
EndTime | String | 2019-06-15T12:10:00Z |
The end of the time range that is queried. |
StartTime | String | 2019-05-30T12:10:00Z |
The beginning of the time range that is queried. |
RequestId | String | 60912B41-7579-4B5D-B289-8856030F0A6A |
The ID of the request. |
PageRecordCount | Integer | 30 |
The number of cross-region data backup files on the current page. |
TotalRecordCount | Integer | 100 |
The total number of entries returned. |
PageNumber | Integer | 1 |
The page number of the returned page. Valid values: any non-zero positive integer. Default value: 1. |
RegionId | String | cn-hangzhou |
The region ID of the instance. |
Items | Array of Item |
An array that consists of details of the cross-region data backup files. |
|
Item | |||
ConsistentTime | String | 2019-06-12T05:44:46Z |
The point in time that is indicated by the data in the cross-region data backup file. |
DBInstanceStorageType | String | ssd |
The storage type. Valid values:
|
CrossBackupId | Integer | 14377 |
The ID of the cross-region data backup file. |
BackupType | String | F |
The type of the cross-region data backup. Valid values:
|
BackupStartTime | String | 2019-05-30T12:10:00Z |
The time when the cross-region data backup started. |
CrossBackupSetLocation | String | oss |
The location where the cross-region data backup file is stored. |
InstanceId | Integer | 8161055 |
The ID of the instance. This parameter is used to determine whether the instance that generates the cross-region data backup file is a primary or secondary instance. |
CrossBackupDownloadLink | String | http://rdsddrbak-shanghai.oss-cn-shanghai.aliyuncs.com/xxxxx |
The external URL from which you can download the cross-region data backup file. |
BackupEndTime | String | 2019-06-15T12:10:00Z |
The time when the cross-region data backup file was generated. |
EngineVersion | String | 5.6 |
The version of the database engine. |
BackupSetStatus | Integer | 0 |
The status of the cross-region data backup. Valid values:
|
CrossBackupSetFile | String | cn-hangzhou_rm-xxxxx_hins81xxx_data_20190612134426_qp.xb |
The name of the compressed package that contains the cross-region data backup file. |
BackupSetScale | Integer | 0 |
The level at which the cross-region data backup file is generated.
|
CrossBackupSetSize | Long | 5312836 |
The size of the cross-region data backup file. Unit: bytes. |
CrossBackupRegion | String | cn-shanghai |
The ID of the destination region where the cross-region data backup file of the instance is stored. |
Category | String | HighAvailability |
The RDS edition of the instance. Valid values:
|
Engine | String | mysql |
The engine of the database. |
BackupMethod | String | P |
The method that is used to generate the cross-region data backup file. Valid values:
|
RestoreRegions | Array of String | "cn-hangzhou", "cn-shanghai" |
An array that consists of the regions to which the cross-region data backup file can be restored. |
Examples
Sample requests
http(s)://rds.aliyuncs.com/?Action=DescribeCrossRegionBackups
&DBInstanceId=rm-uf6wjk5xxxxxxxxxx
&RegionId=cn-hangzhou
&CrossBackupId=14562
&<Common request parameters>
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<DescribeCrossRegionBackupsResponse>
<Items>
<Item>
<CrossBackupSetFile>cn-hangzhou_rm-bpxxxxx_hins798xxxx_data_20190611125201.tar.gz</CrossBackupSetFile>
<BackupSetScale>0</BackupSetScale>
<BackupType>F</BackupType>
<InstanceId>7980000</InstanceId>
<CrossBackupId>14358</CrossBackupId>
<BackupEndTime>2019-06-11T04:55:02Z</BackupEndTime>
<BackupMethod>P</BackupMethod>
<CrossBackupSetLocation>oss</CrossBackupSetLocation>
<CrossBackupSetSize>2179643</CrossBackupSetSize>
<Engine>mysql</Engine>
<BackupStartTime>2019-06-11T04:52:46Z</BackupStartTime>
<CrossBackupDownloadLink>http://rdsddrbak-zb.oss-cn-zhangjiakou.aliyuncs.com/cn-hangzhou_rm-bpxxxxx_hins7986073_data_20190611125201.tar.gz?OSSAccessKeyId=LTAxxxxx&Expires=1560501641&Signature=laK0kxxxxx%3D</CrossBackupDownloadLink>
<Category>HighAvailability</Category>
<CrossBackupRegion>cn-zhangjiakou</CrossBackupRegion>
<RestoreRegions>
<RestoreRegion>cn-hangzhou</RestoreRegion>
<RestoreRegion>cn-zhangjiakou</RestoreRegion>
</RestoreRegions>
<EngineVersion>5.7</EngineVersion>
<DBInstanceStorageType>ssd</DBInstanceStorageType>
</Item>
</Items>
<TotalRecordCount>1</TotalRecordCount>
<PageNumber>1</PageNumber>
<RequestId>60912B41-7579-4B5D-B289-8856030F0A6A</RequestId>
<RegionId>cn-hangzhou</RegionId>
<EndTime>2019-06-11T08:00:00Z</EndTime>
<StartTime>2019-06-10T00:00:00Z</StartTime>
<PageRecordCount>30</PageRecordCount>
</DescribeCrossRegionBackupsResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"Items" : {
"Item" : [ {
"CrossBackupSetFile" : "cn-hangzhou_rm-bpxxxxx_hins798xxxx_data_20190611125201.tar.gz",
"BackupSetScale" : 0,
"BackupType" : "F",
"InstanceId" : 7980000,
"CrossBackupId" : 14358,
"BackupEndTime" : "2019-06-11T04:55:02Z",
"BackupMethod" : "P",
"CrossBackupSetLocation" : "oss",
"CrossBackupSetSize" : 2179643,
"Engine" : "mysql",
"BackupStartTime" : "2019-06-11T04:52:46Z",
"CrossBackupDownloadLink" : "http://rdsddrbak-zb.oss-cn-zhangjiakou.aliyuncs.com/cn-hangzhou_rm-bpxxxxx_hins7986073_data_20190611125201.tar.gz?OSSAccessKeyId=LTAxxxxx&Expires=1560501641&Signature=laK0kxxxxx%3D",
"Category" : "HighAvailability",
"CrossBackupRegion" : "cn-zhangjiakou",
"RestoreRegions" : {
"RestoreRegion" : [ "cn-hangzhou", "cn-zhangjiakou" ]
},
"EngineVersion" : "5.7",
"DBInstanceStorageType" : "ssd"
} ]
},
"TotalRecordCount" : 1,
"PageNumber" : 1,
"RequestId" : "60912B41-7579-4B5D-B289-8856030F0A6A",
"RegionId" : "cn-hangzhou",
"EndTime" : "2019-06-11T08:00:00Z",
"StartTime" : "2019-06-10T00:00:00Z",
"PageRecordCount" : 30
}
Error codes
HTTP Status code | Error code | Error message | Description |
---|---|---|---|
400 | InvalidRegion.Format | Specified Region is not valid. | The error message returned because the specified region is invalid. |
400 | InvalidStartTime.Format | Specified start time is not valid. | The error message returned because the specified start time is invalid. |
400 | InvalidEndTime.Format | Specified end time is not valid. | The error message returned because the specified end time is invalid. Specify a valid value and try again. |
400 | InvalidTime.Format | Specified time is not valid. | The error message returned because the time format is invalid. |
403 | CrossBackupNotSupport | Specified region not support cross region backup. | The error message returned because the specified region does not support the cross-region backup feature. |
404 | InvalidDBInstance.NotFound | Specified instance does not exist or not support. | The error message returned because the instance cannot be found, is deleted, or does not support the operation. |
For a list of error codes, visit the API Error Center.